Most installs unpack to a temp folder. Is there a variable that holds the directory from which a SFX was launched, that can be subsequently used in a script operating from/in the temp folder?
A broader scope of this problem is I would like to simplify the procedure of mounting an .iso which has an autorun inside, for users unfamiliar with iso in general. The iso is fairly large in size and it must be independant from an assistant executable which I'd like to distribute alongside the .iso, which when clicked does the following: 1. Installs virtual drive software (so far IMDisk because its free, universal, lightweight and silent install/uninstall) 2. Mounts the iso (that adjacent to the proposed exectuable) 3. Launches autorun.exe within the iso image that is now loaded on the the newly created virtual drive.
Currently an SFX extracts to temp, silently installs the virtual drive software contain therein. Seperately I have a .cmd script also adjacent to the iso. that mounts the ISO.
The process is easy seperate; the inital working directory in cmd is exectution directory (that of iso), thus can be used with the code in the cmd that needed to mount the iso.
However I would like to consolidate the two actions, the SFX and the .cmd into a single action / icon so to simplify it all.
The iso and 'proposed exe' may be in any directory, so one cannot exactly be specific in the script that is launched in the temp folder - which is why I feel it would be handy knowing if theres possibly a variable that is stored that notes the directory from which the SFX is luanched which one can then use in subsequent scripts enacted by the SFX.
Sorry if this question is loaded i did my best!