How to get homeDirectory
-
i want to get homedirectory of current user like(C:\Documents and Settings\current username). is there any API to get it. Thanks in advance RYK
SHGetFolderPath, just pass in the CSIDL for the desired folder.
-
i want to get homedirectory of current user like(C:\Documents and Settings\current username). is there any API to get it. Thanks in advance RYK
You can call
SHGetFolderPath(CSIDL_PROFILE)
or read the%USERPROFILE%
variable--Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Dunder-Mifflin, this is Pam.
-
i want to get homedirectory of current user like(C:\Documents and Settings\current username). is there any API to get it. Thanks in advance RYK
have a look at
GetUserProfileDirectory
http://msdn2.microsoft.com/en-us/library/aa373772.aspx[^]. :)If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.