By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,572 Members | 963 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,572 IT Pros & Developers. It's quick & easy.

mundane file attributes problerm

P: n/a
Hi,

I have a peculiar problem with trying to assess FileInfo Attributes. I
am trying to do something like this

FileInfo* fi = new FileInfo(fileName);

if (fi->Attributes & Hidden)
{
// ...
}

However, the compiler issues the following errors

error C2039: 'Hidden' : is not a member of 'System::IO'
error C2065: 'Hidden' : undeclared identifier

I have included the proper namespace. Code completion even indicates
Hidden exists in the namespace.

Looking in the help tells me FileAttributes is defined as an
enumeration so the above should be valid.

Any other ideas?

Best regards,
Michael Powell
Nov 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Mike,

Try FileAttributes::Hidden, instead
--
Tomas Restrepo
to****@mvps.org

"Mike" <po******@comcast.net> wrote in message
news:62**************************@posting.google.c om...
Hi,

I have a peculiar problem with trying to assess FileInfo Attributes. I
am trying to do something like this

FileInfo* fi = new FileInfo(fileName);

if (fi->Attributes & Hidden)
{
// ...
}

However, the compiler issues the following errors

error C2039: 'Hidden' : is not a member of 'System::IO'
error C2065: 'Hidden' : undeclared identifier

I have included the proper namespace. Code completion even indicates
Hidden exists in the namespace.

Looking in the help tells me FileAttributes is defined as an
enumeration so the above should be valid.

Any other ideas?

Best regards,
Michael Powell

Nov 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.