Set,"%My_Shortcut_FOLDER%",#$pProgramFiles#$p\%programFolder% Set,"%My_Shortcut_EXE%","%My_Shortcut_FOLDER%\%programExe%"to
If,%ProgramFolder%,Equal,"#$pSystemRoot#$p\system32",Set,"%My_Shortcut_FOLDER%","#$pSystemRoot#$p\system32" If,%ProgramFolder%,NotEqual,"#$pSystemRoot#$p\system32",Set,"%My_Shortcut_FOLDER%","#$pProgramFiles#$p\%programFolder%" Set,"%My_Shortcut_EXE%","%My_Shortcut_FOLDER%\%programExe%"
This way, say, the Regedit script can be changed from this
[Process] If,%pCheckBox1%,Equal,True,Run,%BuildModelScript%,Add-Shortcut,"DE","#$pSystemRoot#$p\system32\regedit.exe","Registry Editor"to this
[variables] %ProgramTitle%=Registry Editor %ProgramEXE%=regedit.exe %ProgramFolder%=#$pSystemRoot#$p\system32 ... [Process] If,%pCheckBox1%,Equal,True,Add_Shortcut,Desktop
This way the api can be used for programs located in the system folder.
My suggestion is that some modification of this sort be made so that app scripts can be written even if their location does not default to the usual program files location.
Regards,
Galapo.