Archive: $APPDATA and Danish NT 4.0


$APPDATA and Danish NT 4.0
Hi,

Running the following script as Administrator under a Danish NT 4.0 with IE 6

OutFile "Setup.exe"
Section
SetShellVarContext current
MessageBox MB_OK $APPDATA
SetShellVarContext all
MessageBox MB_OK $APPDATA
SectionEnd

gives me two times
C:\WINNT\Profiles\Administrator\Programdata
and not
C:\WINNT\Profiles\Administrator\Programdata
and
C:\WINNT\Profiles\All Users\Programdata

Under XP the program works as expected.

Under NT the registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\Common AppData contains C:\WINNT\Profiles\All Users\Programdata
so I can use this as a workaround but I would rather prefer not to.

Is this a known bug/feature?

Best regards,
Jørgen


NSIS simply passes along what the system gives it. That specific system might not support all users folder for the application data. You might not have Internet Explorer 5 installed.

The application data directory. Detection of the current user path requires Internet Explorer 4 and above. Detection of the all users path requires Internet Explorer 5 and above. The context of this constant (All Users or Current user) depends on the SetShellVarContext setting. The default is the current user.