471,354 Members | 1,212 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,354 software developers and data experts.

How to get extended attributes about a file/folder in c#?

I'm writing a web application where I have to present an interface in
browser which looks like a windows explor. I need to populate filename,
size, type, modified date, owner, attributes, etc...
I'm able to get filename, size, type and modified date from FileInfo
class. But I don't know how to get a owner of a file in c#?. Anybody
knows how to get it? (owner of a file can be seen from windows explorer
by right clicking the header on the right pane and selecting the
'owner').

Thanks,
Hari.

Feb 9 '06 #1
2 8865
Hari,

Take a look at this blog post. Brian Noyes uses WMI to get the extended
information:
http://www.softinsight.com/bnoyes/Pe...6-a3697ebc7476

Also, as mentioned in that post you could us P/Invoke to call the Win
API GetSecurityInfo
http://windowssdk.msdn.microsoft.com...curityinfo.asp

Good luck!

-- Tim Scott
http://geekswithblogs.net/tscott

Feb 10 '06 #2

<rh******@gmail.com> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
| I'm writing a web application where I have to present an interface in
| browser which looks like a windows explor. I need to populate filename,
| size, type, modified date, owner, attributes, etc...
| I'm able to get filename, size, type and modified date from FileInfo
| class. But I don't know how to get a owner of a file in c#?. Anybody
| knows how to get it? (owner of a file can be seen from windows explorer
| by right clicking the header on the right pane and selecting the
| 'owner').
|
| Thanks,
| Hari.
|

What's the value of showing the Owner to a web based client?

Willy.
Feb 10 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Chris Stocker | last post: by
2 posts views Thread by Martin Huber | last post: by
5 posts views Thread by JH | last post: by
1 post views Thread by Chris Dunaway | last post: by
reply views Thread by =?Utf-8?B?SGFyZHkgV2FuZw==?= | last post: by
1 post views Thread by =?Utf-8?B?RVFOaXNo?= | last post: by
1 post views Thread by =?Utf-8?B?TWFyaw==?= | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.