Hi
I´ve been working on a portable app, but i´m stuck on moving a directory from a registry key, that contains double back slash in the string, this is the launcher i've created:
[Launch] ProgramExecutable=ThumbsPlus\Bin\thumbs8.exe DirectoryMoveOK=yes [Activate] Registry=true [FileWrite1] Type=Replace File=%PAL:DataDir%\settings\ThumbsPlus.reg Find=="%PAL:LastDrive%%PAL:LastPackagePartialDir%\\ Replace=="%PAL:AppDir%\\ [FileWrite2] Type=Replace File=%PAL:DataDir%\ThumbsPlus\Thumbs8.ini Find==%PAL:LastDrive%%PAL:LastPackagePartialDir%\Data\ Replace==%PAL:DataDir%\ [FileWrite3] Type=Replace File=%PAL:DataDir%\ThumbsPlus\Thumbs8.ini Find==%PAL:LastDrive%%PAL:LastPackagePartialDir%\App\ThumbsPlus\ Replace==%PAL:AppDir%\ThumbsPlus\ [DirectoriesMove] ThumbsPlus=%APPDATA%\ThumbsPlus [RegistryKeys] ThumbsPlus1=HKEY_CURRENT_USER\SOFTWARE\Cerious Software Inc. ThumbsPlus=HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ThumbsPlus SQLite3 ODBC Driver
the problem is that the filewrite1 never works, the reg file is:
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ThumbsPlus SQLite3 ODBC Driver] "UsageCount"=dword:00000001 "Driver"="C:\\Datos\\new\\thumbsplus\\App\\ThumbsPlus\\Odbc\\sqlite3odbc.dll" "Setup"="C:\\Datos\\new\\thumbsplus\\App\\ThumbsPlus\\Odbc\\sqlite3odbc.dll"
I need to replace the string "C:\\Datos\\new\\thumbsplus\\" for something like "%PAL:LastDrive%%PAL:LastPackagePartialDir%\\" or "%PAL:LastDrive:DoubleBackslash%%PAL:LastPackagePartialDir:DoubleBackslash%\\"
could you please help me on solving this?
thanks in advance
[Code formatted and whatnot - mod Chris]
 
      
 Visit the Community page
 Visit the Community page Join our forums
 Join our forums Subscribe to our email newsletter
 Subscribe to our email newsletter Subscribe with RSS
 Subscribe with RSS Follow us on BlueSky
 Follow us on BlueSky Follow us on Facebook
 Follow us on Facebook Follow us on LinkedIn
 Follow us on LinkedIn Follow us on Mastodon
 Follow us on Mastodon
EDIT: Is the HTML or there's a space between
C:\\Datos\\new\\thumbsplusand\\App\\...?Also, your
[FileWrite]s need some fixing. I don't know what would be the best way to do what you're trying, but Chris should be able to help you.@ChrisMorgan: what's the current equivalent to
%PAL:LastDataDir%(considering Live mode)?Previously known as kAlug.
There is no equivalent at present; I intend to add a mechanism to deal with in 2.2 (I'd forgotten to add it to my TODO list - thanks for reminding me). For the moment, replacing on drive and partial directory (and generally doing them separately will be better, as the drive will often appear without being followed by the package path) is the way to do it.
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
Please feel free to suggest anything you consider that I can improve on the launcher.
thanks for your reply, It could be nice if examples like this were added to the PAL Launcher manual.