|
-
March 1st, 2010, 07:08 AM
#1
how to enumerate files in the Mydocument in vista and windows 7
hello,
i have a client application running under the user Account. which retrieves the MyDocuments path through
SHGetFolderPath( NULL, CSIDL_MYDOCUMENTS, NULL, 0, szPath );
i am passing this path to my service that will enumerate the files in this folder. but i get access denied while doing this when i use FindFirst API.
can someone please tell how could i fix this. i want to use LogOn APIs only as a last resort.
can'nt i do it after applying some securities settings.
regards
d
-
March 3rd, 2010, 08:30 AM
#2
Re: how to enumerate files in the Mydocument in vista and windows 7
Are you aware that....
SHGetFolderPath Function
Deprecated. Gets the path of a folder identified by a CSIDL value.
Note As of Windows Vista, this function is merely a wrapper for SHGetKnownFolderPath. The CSIDL value is translated to its associated KNOWNFOLDERID and then SHGetKnownFolderPath is called. New applications should use the known folder system rather than the older CSIDL system, which is supported only for backward compatibility.
It appears that CSIDL_MYDOCUMENTS may not be supported in this implementation. Try using the equivalent FOLDERID_Documents with SHGetKnownFolderPath.
Gort...Klaatu, Barada Nikto!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|