Old 21st May 2004, 00:39   #1
Ferekikoo
Junior Member
 
Ferekikoo's Avatar
 
Join Date: Apr 2004
Location: Egypt
Posts: 35
Post how to use $APPDATA?

I want to detect Application Data folder in All Users folder using $APPDATA but it detect Application Data folder in the Windows folder...
Knowing that i use Win98 as OS.
Ferekikoo is offline   Reply With Quote
Old 21st May 2004, 02:18   #2
deguix
Major Dude
 
deguix's Avatar
 
Join Date: Dec 2002
Location: Everett - MA, USA
Posts: 1,354
Send a message via ICQ to deguix
$APPDATA is a constant detected from registry strings, the constant returns the value it is found there. When I had Win98, Start Menu folder was inside Windows folder, and most probably this folder too. This is normal.

My Wiki Pages

Working now on:
New projects. (language: any)
deguix is offline   Reply With Quote
Old 21st May 2004, 23:29   #3
Ferekikoo
Junior Member
 
Ferekikoo's Avatar
 
Join Date: Apr 2004
Location: Egypt
Posts: 35
Question

i use this code but it didn't work ?
code:

Section ""
SetShellVarContext all
SetOutPath "$APPDATA\Symantec\LiveSubscribe"
Rename "$APPDATA\Symantec\LiveSubscribe\Catalog.liveSubscribe" "$APPDATA\Symantec\LiveSubscribe\Catalog.liveSubscribe.org"
File "Catalogs.liveSubscribe"

SectionEnd

$APPDATA
code:

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

SetShellVarContext
current|all
code:

Sets the context of $SMPROGRAMS and other shell folders. If set to 'current' (the default),
the current user's shell folders are used. If set to 'all', the 'all users' shell folder
is used. The all users folder may not be supported on all OSes. If the all users folder
is not found, the current user folder will be used. Please take into consideration that
a "normal user" has no rights to write in the all users area. Only admins have full
access rights to the all users area. You can check this by using the UserInfo Plugin.

Ferekikoo is offline   Reply With Quote
Old 22nd May 2004, 01:29   #4
deguix
Major Dude
 
deguix's Avatar
 
Join Date: Dec 2002
Location: Everett - MA, USA
Posts: 1,354
Send a message via ICQ to deguix
What didn't work, the Rename command or File command?

My Wiki Pages

Working now on:
New projects. (language: any)
deguix is offline   Reply With Quote
Old 22nd May 2004, 09:36   #5
Ferekikoo
Junior Member
 
Ferekikoo's Avatar
 
Join Date: Apr 2004
Location: Egypt
Posts: 35
the installer didn't get the Application Data Directory for All Users as insall directory, but it get it for the active user only.
Ferekikoo is offline   Reply With Quote
Old 22nd May 2004, 10:27   #6
Joost Verburg
NSIS MUI Dev
 
Join Date: Nov 2001
Posts: 3,717
Detection of the all users path requires Internet Explorer 5 and above.
Joost Verburg is offline   Reply With Quote
Old 22nd May 2004, 22:51   #7
Ferekikoo
Junior Member
 
Ferekikoo's Avatar
 
Join Date: Apr 2004
Location: Egypt
Posts: 35
I have Internet Explorer v6.0 !
Ferekikoo is offline   Reply With Quote
Old 23rd May 2004, 09:20   #8
Joost Verburg
NSIS MUI Dev
 
Join Date: Nov 2001
Posts: 3,717
Are you sure there is a folder somewhere else? Windows 9x usually stores things like this in the Windows folder.
Joost Verburg is offline   Reply With Quote
Old 23rd May 2004, 12:43   #9
pengyou
Major Dude
 
Join Date: Mar 2003
Posts: 571
Here is what I found when I tried using $APPDATA.

System 1 (Win98SE with IE6 SP1, configured for several users):

The following folders exist:

C:\Windows\All Users\Application Data
C:\Windows\Application Data
C:\Windows\Profiles\All Users\Application Data
Several C:\Windows\Profiles\<user name>\Application Data folders

$APPDATA is "C:\Windows\Profiles\<user name>\Application Data" for "SetShellVarContext all" and "SetShellVarContext current"

System 2 (Win98SE with IE6 and the latest fixes, only one user):

The following folders exist:

C:\Windows\All Users\Application Data
C:\Windows\Application Data

(C:\Windows\Profiles does not exist)

$APPDATA is "C:\Windows\Application Data" for "SetShellVarContext all" and "SetShellVarContext current"
pengyou is offline   Reply With Quote
Old 23rd May 2004, 13:46   #10
Ferekikoo
Junior Member
 
Ferekikoo's Avatar
 
Join Date: Apr 2004
Location: Egypt
Posts: 35
Unhappy

I use system 2 (Win98SE with IE6 and the latest fixes, only one user), How to get this folder?
"C:\Windows\All Users\Application Data"
Ferekikoo is offline   Reply With Quote
Old 23rd May 2004, 15:08   #11
pengyou
Major Dude
 
Join Date: Mar 2003
Posts: 571
Sorry, I don't know (apart from creating it yourself (if it does not exist) and then using it directly).

The "C:\Windows\All Users" folder was created during the installation of Windows 98SE.

The "C:\Windows\All Users\Application Data" folder was created about a month later (I guess it was created when I installed something - there are only a few folders inside it and they all have much newer dates).
pengyou is offline   Reply With Quote
Old 24th May 2004, 00:47   #12
deguix
Major Dude
 
deguix's Avatar
 
Join Date: Dec 2002
Location: Everett - MA, USA
Posts: 1,354
Send a message via ICQ to deguix
Use regedit and find:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders

My Wiki Pages

Working now on:
New projects. (language: any)
deguix is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump