Old 29th November 2007, 08:09   #1
Dexterito
Junior Member
 
Join Date: Nov 2007
Posts: 1
Need help with all users!

Hello!

I'm creating some instalation and i have to copy config file in application data folder for every user. I use propertu
SetShellVarContext all but then the config file is copied into C:\documents and settings\All users\Application data but not for each user! and if for windows add some new user,then need that config file to copy for the new user too!

Maybe someone have some suggestions?

Dexter
Dexterito is offline   Reply With Quote
Old 29th November 2007, 09:00   #2
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,192
You could enumerate the users at install time, load their profile and copy to their appdata folder, but that would not solve the new user problem (And users that don't want to use your program get useless files in their profile). Why not store a basic config file in programfiles or common files and add some logic to your program instead that will copy the base config to the users appdata the first time the user runs your program

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 29th November 2007, 09:33   #3
CancerFace
Senior Member
 
Join Date: Apr 2006
Posts: 289
Send a message via ICQ to CancerFace
If you want new users to get the config file you should also place it in C:\documents and settings\Default User\Application data.

However Anders has a good point, it may be more functional to copy the config file to a user's AppData folder when they execute your program for the first time.

CF
CancerFace 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