开发者

Where is `USERPROFILE` on Vista32?

This is a follow-up question to Where are my environment variables set?. In that post it's mentioned how one can find environment variables using the Windows GUI or RegEdit. What's strange to me is that SET from the command line displays a USERPROFILE=C:\Users\brianjd but it doesn't show up using the Windows GUI or 开发者_运维技巧RegEdit methods.

Q: Where is USERPROFILE? Why does it show up using SET but doesn't show up using Windows GUI or RegEdit?


I think you may find what you need in HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\ProfilesDirectory

Each user has it's own Profile key as well, which stores the ProfileImagePath (and is set to the same value as %userprofile%)

It may explain why this is not a environment variable that appears in the GUI.

I don't have any source to confirm that sorry. But I had to use this to repair a broken profile last week. Hope it helps.

M'vy


I'm guessing it is set by winlogon.exe or userinit.exe when you log in. Clearly, the USER* variables have to be set by the system since domain and profile path can change.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜