Jul 20, 2015
10:39 AM
Just in case someone else is trying to do something similar, i have managed to get it to work function CopyUserManual(hMSI) STRING dataPath, error, sourcePath; NUMBER nvType, nvSize, nResult, nBufferSize; begin RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE); RegDBGetKeyValueEx("SOFTWARE\\EuroAvionics\\EasyTask", "ETGSDataPath", nvType, dataPath, nvSize); if (StrLengthChars(dataPath) > 0) then //Do Nothing else RegDBGetKeyValueEx("SOFTWARE\\Wow6432Node\\EuroAvionics\\EasyTask", "ETGSDataPath", nvType, dataPath, nvSize); endif; nBufferSize = MAX_PATH; MsiGetProperty(ISMSI_HANDLE, "SETUPEXEDIR", sourcePath, nBufferSize); nResult = CopyFile(sourcePath ^ USER_MANUAL_NAME, dataPath ^ USER_MANUAL_NAME); error = FormatMessage(nResult); end; Luckily we were already storing the datapath selected during the install in the registry as we need it when the program runs so i can use that as the destination. Getting the source path proved more challenging as the installer thinks it is running from a temp directory as that is where it is extracted to. In the end i found the SETUPEXEDIR which points to the actual exe location.
... View more
Jul 17, 2015
06:27 AM
I have finally got around to trying this (ran out of actual work to do!!!) and have made progress function CopyUserManual(hMSI, destDirectory) NUMBER nResult; STRING error; STRING sourcePath; begin sourcePath = SourceDir; nResult = CopyFile(sourcePath ^ USER_MANUAL_NAME, destDirectory ^ USER_MANUAL_NAME); error = FormatMessage(nResult); end; There is a path set during the installation that holds the data files and the User Manual needs to go in there as well. If i put in a proper path instead of destDirectory it works fine, however i need to pass that value in from the installer. Is there a way to do this? Thanks
... View more
May 26, 2015
08:33 AM
Thanks for the reply, basically yes that is what i am attempting to do I was afraid that was the answer, unfortunately this is a requirement from higher up and was dumped on my desk!!! I requested a reason at the time as to why the user manual could not be produced in time to go with the release and there has been no answer!!, not really a surprise though Looking at my options i think the best is the custom action route, our installer is only about 200MB so there is no issue on size at all Thanks for the additional actions regarding uninstall as i probably would have forgotten about them Regards Ross
... View more
May 22, 2015
07:22 AM
Hi, I have been looking into this issue for about 4 hours and have got pretty much nowhere, it cannot be that hard surely? All i am trying to do is copy a file from the same destination as the installer into the install directory. This needs to be done as the user manual is never ready to go when the installer is built so i am looking for a way to have the user manual on the CD and then it gets copied into the install directory after the install. I have been attempting to do this with the MoveFile table and have set up an entry as below FileKey : CopyUserManual Component : UserManual SourceName : User Manual.pdf DestName: User Manual.pdf SourceFolder : SOURCEDIR DestFolder : INSTALLDIR Options : 1 At first the installer didn't work at all as i hadn't included the component in the project. I did that and then the installer ran but the file was not copied Does anyone have any ideas as to where i am going wrong?? Thanks in advance Ross
... View more
Labels
- Labels:
-
InstallShield 2013
Latest posts by rfarley
Subject | Views | Posted |
---|---|---|
1672 | Jul 20, 2015 10:39 AM | |
1672 | Jul 17, 2015 06:27 AM | |
1672 | May 26, 2015 08:33 AM | |
2666 | May 22, 2015 07:22 AM |
Activity Feed
- Posted Re: Copy file from CD to install directory on InstallShield Forum. Jul 20, 2015 10:39 AM
- Posted Re: Copy file from CD to install directory on InstallShield Forum. Jul 17, 2015 06:27 AM
- Posted Re: Copy file from CD to install directory on InstallShield Forum. May 26, 2015 08:33 AM
- Posted Copy file from CD to install directory on InstallShield Forum. May 22, 2015 07:22 AM