![]() |
drive of windows installed
sir,
anybody have the code of getting the drive name (eg: C:\, D:\) where windows installed for a nsis file? . i created a setup program to install my program using nsis. now i coded C:\ or D:\ directly on the code, but i want the setup program to check whether the windows installed on C:\ or D:\ and that drive letter shown in setup program to install . any help?? with regards G.H.Kumar |
you could just make use of e.g. $SYSDIR (the full path to the system32 folder, which I think you can't change from the windows installation drive's; unless you did some major hacking after install, I suppose), and then just grab the drive from that using string manipulation.
|
StrCpy $YourVar "$SYSDIR" 3
This will give you C:\ Change the number to change the number of characters (i.e. 1-C, 2-C:, 3-C:\, etc) |
code: |
| All times are GMT. The time now is 17:27. |
Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.