Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   Has GetDrives Stopped Enumerating Mapped Drives in Windows7 ? (http://forums.winamp.com/showthread.php?t=339525)

nsnb 16th December 2011 17:58

Has GetDrives Stopped Enumerating Mapped Drives in Windows7 ?
 
I have been using the very useful GetDrives function for a while, but only today I discovered that while it continues to work perfectly on Windows XP, it doesn't list network-mapped drives on Windows 7.

(I tried both the default "ALL" and the more specific "FDD+HDD+CDROM+NET+RAM" option)

Is this known behavior?

Any suggestion how to enumerate all drives (including mapped network shares) on Windows 7?

MSG 16th December 2011 19:24

Could it be related to elevation? http://forums.winamp.com/showthread.php?t=339478

pengyou 16th December 2011 19:39

GetDrives works on my Windows 7 Professional SP1 (64-bit) system, Here are the results from a test using "NET":
code:
X:\ (NET Drive)
Y:\ (NET Drive)


Tested using NSIS 2.45 using RequestExecutionLevel "user"

nsnb 16th December 2011 20:09

Quote:

Originally Posted by pengyou (Post 2826692)
GetDrives works on my Windows 7 Professional SP1 (64-bit) system, Tested using NSIS 2.45 using RequestExecutionLevel "user"

This is very interesting. I use:

Quote:

RequestExecutionLevel admin
Which should intuitively provide more access to the system, not less.

I will test this with user and see what happens.

(BTW, I am using NSIS 2.45, too. I should upgrade to the latest 2.46, I know.)

pengyou 16th December 2011 22:49

I forgot to mention that I ran my test from a standard account, not an administrator account.

MSG 17th December 2011 06:01

Quote:

Originally Posted by nsnb (Post 2826696)
This is very interesting. I use:

requestexecutionlevel admin

Which should intuitively provide more access to the system, not less.

Anders did suggest that drive mapping (which are per-user) may not survive elevation. Intuitively, that seems pretty reasonable.

pengyou 17th December 2011 11:20

Anders is right - if you elevate then GetDrives can only see the drives mapped by the administrative rights account.

My admin account does not have any mapped drives so when I re-ran my test with RequestExecutionLevel "admin" the GetDrives NET option did not find anything.

Anders 19th December 2011 10:40

http://blogs.msdn.com/b/cjacks/archi...ows-vista.aspx

nsnb 13th January 2012 15:57

Quote:

Originally Posted by Anders (Post 2827232)

Anders, you are the forum king. Thank you!


All times are GMT. The time now is 17:33.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.