Old 1st October 2016, 03:36   #1
ivaldes1
Junior Member
 
Join Date: Dec 2009
Posts: 12
Simplest way to add subdirectories to Users\Username?

I need to add the path .CPRS\Cache\Temp.html or just .CPRS\Cache to the Users\Username subdirectory. What is the simplest way of doing this? Also for Windows 7-10 will this require administrator auth? Many thanks! Getting close.
ivaldes1 is offline   Reply With Quote
Old 1st October 2016, 11:29   #2
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,504
Are you talking about the same user as the user that is running the installer or a specific hardcoded username? You don't need to elevate to write to your own profile.

Take a look at the constants section in the help file.

On a personal note, I hate it when applications adds folders to my profile root. Your path contains the names "Cache" and "Temp" so you really should put it under $LocalAppData!

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 4th October 2016, 03:44   #3
ivaldes1
Junior Member
 
Join Date: Dec 2009
Posts: 12
User running the installer. So you SetOutPath "$LocalAppData" then create .CPRS\Cache but I'm not sure from the wiki what is the actual command to create subdirectories like .CPRS\Cache?
ivaldes1 is offline   Reply With Quote
Old 4th October 2016, 03:45   #4
ivaldes1
Junior Member
 
Join Date: Dec 2009
Posts: 12
Ah, CreateDirectory :-)
ivaldes1 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