Page 1 of 1

Duplicate script from one install to another

Posted: Tue Jul 26, 2011 2:33 pm
by gsaunders
I know I can copy and paste script commands from one install to another, but what I was wondering if there is a way to duplicate a complete script from one install to another.

For example... I have a customized updates script that was in one installer. I wanted to take that same updates script and make it part of another install. Is there a file(s) that can be simply copied that would bring over just the scripting for updates script?

Also wanting to better understand where all the scripts are saved. In the folder where the .mpr file is located I see a lot of .dfm and .miaf, but I don't see any script.

Thanks,

Greg

Re: Duplicate script from one install to another

Posted: Tue Jul 26, 2011 8:08 pm
by giaviv
Hi Greg,

Actually, all scripts are saved in the project folder, so you can copy your script file to it and use the Included Scripts section in the MSIcode tab to include it with your project.

Re: Duplicate script from one install to another

Posted: Wed Jul 27, 2011 7:40 am
by gsaunders
giaviv wrote:Hi Greg,

Actually, all scripts are saved in the project folder, so you can copy your script file to it and use the Included Scripts section in the MSIcode tab to include it with your project.
I thought they were as well, but I didn't see them. Apparently I had not hit save under the new project so the updates.* files were not there. Amazing how things show up by hitting that one little button! :oops:

Re: Duplicate script from one install to another

Posted: Wed Jul 27, 2011 10:49 am
by giaviv
:)

Re: Duplicate script from one install to another

Posted: Thu Jul 28, 2011 9:02 am
by gsaunders
giaviv,

Hmmm... Because I thought there was something strange about not seeing the files previously I decided to start a completely new project and test things again.

I did the following:

1) I created the project under v1.0 folder.
2) Enabled Manual Update Checking. ( I see in the MSICode the include script updates.
3) I save everything, but do NOT see the updates.* files in project folder.
4) I created an update by doing a save as for the project to a different folder v1.5.
5) I look and still see the update file with the same edits... but don't see the file.
6) I then make a change and save it. Then I go back to the older project and see the change there as well.

So where the heck is it??? I thought maybe it was using a default one somewhere else until I make a change so I made a change and saved it.

On previous install project I somehow evenually go the following files to show up (updates.mia, updates.mia.brk, updates.mia.fld, updates.mia.txt)... BUT they are not showing up in this new project and one of my older ones... even though I have updates enabled and change the updates script.

I was trying to see if there was a way to see what location the file tied to the tabl updates was located, but don't see how.

Greg

Re: Duplicate script from one install to another

Posted: Thu Jul 28, 2011 10:10 am
by gsaunders
gsaunders wrote:giaviv,

Hmmm... Because I thought there was something strange about not seeing the files previously I decided to start a completely new project and test things again.

I did the following:

1) I created the project under v1.0 folder.
2) Enabled Manual Update Checking. ( I see in the MSICode the include script updates.
3) I save everything, but do NOT see the updates.* files in project folder.
4) I created an update by doing a save as for the project to a different folder v1.5.
5) I look and still see the update file with the same edits... but don't see the file.
6) I then make a change and save it. Then I go back to the older project and see the change there as well.

So where the heck is it??? I thought maybe it was using a default one somewhere else until I make a change so I made a change and saved it.

On previous install project I somehow evenually go the following files to show up (updates.mia, updates.mia.brk, updates.mia.fld, updates.mia.txt)... BUT they are not showing up in this new project and one of my older ones... even though I have updates enabled and change the updates script.

I was trying to see if there was a way to see what location the file tied to the tabl updates was located, but don't see how.

Greg
Hmmm... I found the files in the C:\Program Files\InstallAware\InstallAware11 folder. And I see my minor changes in these files. Shoudn't those files have be copied into the project location when I created the project originally and asked it to allow updating??? Why did it start editing from that location. So do new projects inherit this one. Anyway... need to keep this from happening.

Re: Duplicate script from one install to another

Posted: Thu Jul 28, 2011 12:36 pm
by gsaunders
gsaunders wrote: Hmmm... I found the files in the C:\Program Files\InstallAware\InstallAware11 folder. And I see my minor changes in these files. Shoudn't those files have be copied into the project location when I created the project originally and asked it to allow updating??? Why did it start editing from that location. So do new projects inherit this one. Anyway... need to keep this from happening.
I figured out what had happened.

During several of my tests where I wanted the updates script to go back to the default I simply deleted the updates.* from the project folder thinking it would recreate them. But what happened is instead of recreating them it simply changed it's pointer to the default on in the C:\Program Files\InstallAware\InstallAware11 folder.

I was able to copy it to the project folder and fixed the path in the .mpr file and now things are good.

From now on I will just make sure I COPY the full folder from VersionOld to VersionNew so I have everything. This way I keep a history of things.

Re: Duplicate script from one install to another

Posted: Fri Jul 29, 2011 12:46 am
by giaviv
Thanks for sharing!

Re: Duplicate script from one install to another

Posted: Fri Jul 29, 2011 7:44 am
by gsaunders
giaviv wrote:Thanks for sharing!
Your welcome... the key here is if you want to go back to the default base script... do NOT just delete from your project folder and expect it to rebuild... but copy the default one from the InstallAware runtime folder C:\Program Files\InstallAware\InstallAware 11\runtimes (based on my machine).

It would be cool if there was an option to tell the current script to revert back to the default script so the system could handle the copy for you. But I can certainly do it manually.