redirect a absolute path to a relative path?

Discuss anything related to JauntePE, the utlimate utility to help you tame non-portable applications. Share your experience about the apps that work with JauntePE, and the apps that don't.
Post Reply
Message
Author
McMic
Posts: 4
Joined: Fri Sep 03, 2010 3:59 am

redirect a absolute path to a relative path?

#1 Post by McMic »

Hi Volks,

i have successful portalized a Programm (TippKonigin - look my other Post)
But on little bug-thing:

Tippkonigin writes back a path in a ini-file.
It write a absolute path, looks like:

Code: Select all

DataFileName=E:\TippKonigin\JPE\ProgramFiles\TippKonigin\Ubungen\Lektionen\Lektion_09.txt
Is JauntePE able to redirect this absolute path to a relative one? And if yes, how?

Tippkonigin also work with a relative path to open the file

Code: Select all

DataFileName=Lektionen\Lektion_09.txt
, but always save a absolute.

Thanks in advance

Mike

crownixx
Posts: 403
Joined: Sat May 12, 2007 6:26 am

Re: redirect a absolute path to a relative path?

#2 Post by crownixx »

McMic wrote:Is JauntePE able to redirect this absolute path to a relative one? And if yes, how?
No.
JauntePE can redirect the absolute path but cannot convert one into relative path.

To troubleshoot this problem, again try to think like TippKonigin.
Is "Lektion_09.txt" file saved by yourselft or the program save the file by itself? (get my question? :p)

If you are the one that saving the file "Lektion_09.txt",
try save the file by browsing to "C:\Program Files\TippKonigin\Ubungen\Lektionen\Lektion_09.txt" instead. Hopefully TippKonigin will write the ini file with path "C:\Program Files\TippKonigin\Ubungen\Lektionen\Lektion_09.txt". Next time when TippKonigin read the path, it will "think" the path is exist and will load the file "Lektion_09.txt" successfully. Remember that i told you before TippKonigin got fooled by JauntePE? :P
Now, when playing your program, use "C:\Program Files\TippKonigin" as your relative path. Get it what i mean?
That is how portablizing through virtualization work. JauntePE cannot convert the absolute path to relative path like any nsis launcher does.

If TippKonigin save the file "Lektion_09.txt", then you still have the same trouble redirecting the path "C:\Program Files\TippKonigin".
Try to redirect the application directory itselft
[Redirection]
ExcludeAppDir=0
or use token %appdir% in the path you like to redirect and put the path in the [FilesystemInclude]

Post Reply