You are here

Portableapps.com Launcher ALLUSERSPROFILE problem?

9 posts / 0 new
Last post
judeah666
Offline
Last seen: 10 years 7 months ago
Joined: 2009-03-28 15:53
Portableapps.com Launcher ALLUSERSPROFILE problem?

is this right?
ALLUSERSPROFILE

in XP its C:\Documents and Settings\All Users
and in vista its C:\ProgramData

i think this is wrong cause when i open a file in vista it works fine but when i open the same file in XP it needs to be in C:\Documents and Settings\All Users\Application Data, so i added "\Application Data" like this "&ALLUSERSPROFILE&\Application Data" in move directories and opened it in xp it works fine but in vista it turns out like this C:\ProgramData\Application Data

and i'm having some trouble in reg [RegistryCleanupForce] this only deletes the key, but i just want to delete the value like this

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts\Arial (TrueType)=REG_SZ:arial.ttf

i only need to delete the value "Arial (TrueType)" not the whole "Fonts" key

i tried [RegistryValueBackupDelete] but so far no go.

sometimes when i open the app it gets an error like -changedir and -UAC.
john said that The directory Application Data will vary depending on OS language

[Moved from General Discussion forum to Portable App Development forum by mod Chris]

Mark Sikkema
Offline
Last seen: 13 years 3 months ago
Developer
Joined: 2009-07-20 14:55
Custom code

In NSIS, to use the ALLUSERSPROFILE use:

SetShellVarContext all

and to set it back use:

SetShellVarContext current

Then just make use of the "$APPDATA" variable ! The variable $APPDATA takes care of the different paths for different OS's
Anyhow, I bet the launcher needs admin privileges for this.

About the registry, [RegistryValueBackupDelete] should really take care of this, make sure you didn't make any typos.

Formerly Gringoloco
Windows XP Pro sp3 x32

Chris Morgan
Chris Morgan's picture
Offline
Last seen: 9 years 6 months ago
Joined: 2007-04-15 21:08
ALLUSERSPROFILE

For confirmation of the environment variables, refer to the manual; ALLUSERSPROFILE is indeed that. Naturally then if you put "\Application Data" after that, it'll go that way for all users. Also in using strings like "Application Data", bear in mind languages - in other languages the directory actually has a different name.

As Gringoloco says, to get what you're needing you will at the moment need custom code at the moment. I'll check into it and see about improving it for 2.1.

I am a Christian and a developer and moderator here.

“A soft answer turns away wrath, but a harsh word stirs up anger.” – Proverbs 15:1

judeah666
Offline
Last seen: 10 years 7 months ago
Joined: 2009-03-28 15:53
Another reg sharedlls

ok i decided to just have allusersprofile and allusersappdata and automatically delete it so no harm done.

the other problem is stumbled in a sharedllls reg just like the fonts and registryvaluebackupdelete wont work because what it does is backup the value and delete it when the app is open but the app needs it to open and i can't just use the cleanupforce or clenupifempty because it will mess up windows.

Chris Morgan
Chris Morgan's picture
Offline
Last seen: 9 years 6 months ago
Joined: 2007-04-15 21:08
%ALLUSERSPROFILE%\Application Data

I think that %ALLUSERSPROFILE%\Application Data should actually be safe; in Vista/7 there's a symlink/junction (can't remember which) for C:\ProgramData\Application Data to C:\ProgramData; thus I think it should be OK using %ALLUSERSPROFILE%\Application Data for the moment, though it's not the ideal solution.

As for shared DLLs, that's something I'm planning on looking into more closely; at the moment I have DLL server registration (without backup which I need to do), and shared DLLs are very similar to that.

(If these feature requests keep coming along I may split them into two releases, 2.1 and then 2.2, lest 2.1 have too many new features and there be almost nothing left for 2.2 and 2.3... this uptake of it and usage of features not reasonable before is pleasing to see. Smile Thanks for using the PortableApps.com Launcher :-))

I am a Christian and a developer and moderator here.

“A soft answer turns away wrath, but a harsh word stirs up anger.” – Proverbs 15:1

Chris Morgan
Chris Morgan's picture
Offline
Last seen: 9 years 6 months ago
Joined: 2007-04-15 21:08
ALLUSERSAPPDATA added

An environment variable ALLUSERSAPPDATA has been added to PAL 2.1.

I am a Christian and a developer and moderator here.

“A soft answer turns away wrath, but a harsh word stirs up anger.” – Proverbs 15:1

judeah666
Offline
Last seen: 10 years 7 months ago
Joined: 2009-03-28 15:53
how to

am i just gonna overwrite the variables.nsh. i'm gonna test it later tnx

Chris Morgan
Chris Morgan's picture
Offline
Last seen: 9 years 6 months ago
Joined: 2007-04-15 21:08
?

You just use the development build until 2.1 is released.

I am a Christian and a developer and moderator here.

“A soft answer turns away wrath, but a harsh word stirs up anger.” – Proverbs 15:1

judeah666
Offline
Last seen: 10 years 7 months ago
Joined: 2009-03-28 15:53
Can't Wait

Can't wait for the 2.1 release. i do hope that if you release it it's just gonna be minor bugs or no bugs at all

Log in or register to post comments