cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
kmitchell
Level 3

Some very basic questions - new to install shield

Hi all!

First, thanks in advance for any help anybody might be able to provide with my issue. I really appreciate it.

Now, my issue: I was given an Install Shield 2008 License, an ISM file (saved Install Shield project file), and a directory with a bunch of files in it. These were (roughly) all of the files that were used to create the current installer that my company uses for a product we sell. This installer was made about 9 months ago by somebody who is no longer working on the project. My task is to 1) get the installer working on my machine and 2) add in an exe that needs to run during the install in order to install a camera drive.

As of now, I'm stuck on step 1. I started by opening the previous project (ism file) in IS2008, going to the "Installation Designer", going to the "Path Variables" section, and pointing all of the paths that were listed to their new directories on my computer.

After this, I tried compiling the project (using the "Release Wizard"). I was given the approximate steps to work my way through the wizard, (build for a CD, one disk, english, install .NET 1.1, generate .inf file, etc). I got a bunch of errors. Slowly I tried to work my way through them, locating missing files, googling error codes and doing random things (setting key files, etc, etc).

I FINALLY was/am able to almost totally build the project (again, with the "release wizard"). Once I build the project, I am left with two warning messages about duplicate files, and a bunch of icon error messages. I was told that the icon error messages have always happened in the past, and not to worry about them (?).

When I actually run the installer, things seem to be going well. The installer starts, a separate installer starts for a driver (this is supposed to happen), once the driver install exits the install shield installer continues. Copying files, registering... then BAM, right as it seems everything is going to complete, I get "Rolling Back"... It was almost (ALMOST) funny the first time I saw this happening, the status bars going backwards.

I googled, and found out I can look at the logfile from the install. I did this, but while I can make out the general spot where things start rolling back, I don't see anything that makes much sense to me before that. No giant "ERROR, UNABLE TO DO _______, ROLLING BACK" or something.


At this point I'm just looking for some general advice. Is there any way for me to find out why the installer is stopping/rolling back? Is there anything in particular to look at in the logfile?

Again, I've never even looked at Install Shield, and I was handed this project with a fast approaching deadline. I'd love to fully understand IS2008, what everything is and how exactly it works (it's in my nature), but for now I don't really have the luxury.


So again, I'd be thrilled with any general tips/hints!

Thank you very much!


edit: bonus, sub question: There is a .prq (prerequisite) file that the installer is looking for, for some reason. I don't believe there should be a prereq, is there somewhat of stopping install shield from looking for this .prq file? I googled and found that going to tools -> prereq editor (or osmething like that) I could make a new prereq. However, when I try my installer, I get a dialog that pops up asking if I want to continue and notifying me of the prereq (MyPrerequisiteOne or something). I click continue and all is well (seemingly). If I delete this PRQ file then when I run the installer I get an message (something like) "cannot extract _________". I click "OK", and again the installer continues. Magic.
Labels (1)
0 Kudos
(5) Replies
Kelter
Level 10

Project type? "InstallScript MSI' or "Basic MSI" (it appears in [] in the title bar of the IS IDE)


I FINALLY was/am able to almost totally build the project (again, with the "release wizard"). Once I build the project, I am left with two warning messages about duplicate files, and a bunch of icon error messages. I was told that the icon error messages have always happened in the past, and not to worry about them (?).

If multiple features include the same file, that file should belong to a single component, and that one component should be associated with whatever features are necessary. this is just the first thing that pops into my mind when it comes to duplicate files errors, but if you could be more specific about the error, we could be a bit more helpful.

you can probably track down each icon error, take it literally, and see what might be wrong. when creating a start menu shortcut, the designer will use the target file and iconindex=0 to assign the icon file. if this is not valid, pick something that is.

I googled, and found out I can look at the logfile from the install. I did this, but while I can make out the general spot where things start rolling back, I don't see anything that makes much sense to me before that. No giant "ERROR, UNABLE TO DO _______, ROLLING BACK" or something.


if you select "MSI Log Analyzer" from the "Tools" menu, and use that to view your log file, you'll quickly find where teh failure happened. if you just want to search the log for something, look for "Return value 3" or "Return value 2".

if an InstallScript custom action fails with a "2" then you know that "abort" was called. a "3" means the CA returned something other than ISERR_SUCCESS (which equals 0). also, if an IS CA is failing without throwing up a MessageBox, then perhaps it should be authored to do so...otherwise when a customer has an issue with the installation and you haven't reproduced the problem in-house, you'll have NOTHING to go on to help troubleshoot the customer issue. (or if you're a n00b trying to figure out another person's project... 😛 )

alas, i don't know much about using prerequisites, but you need to disassociate a prereq from the project, rather than simply deleting the file from which the project expects to get information on its prereqs.
0 Kudos
kmitchell
Level 3

Kelter wrote:
Project type? "InstallScript MSI' or "Basic MSI" (it appears in [] in the title bar of the IS IDE)


If multiple features include the same file, that file should belong to a single component, and that one component should be associated with whatever features are necessary. this is just the first thing that pops into my mind when it comes to duplicate files errors, but if you could be more specific about the error, we could be a bit more helpful.

you can probably track down each icon error, take it literally, and see what might be wrong. when creating a start menu shortcut, the designer will use the target file and iconindex=0 to assign the icon file. if this is not valid, pick something that is.



if you select "MSI Log Analyzer" from the "Tools" menu, and use that to view your log file, you'll quickly find where teh failure happened. if you just want to search the log for something, look for "Return value 3" or "Return value 2".

if an InstallScript custom action fails with a "2" then you know that "abort" was called. a "3" means the CA returned something other than ISERR_SUCCESS (which equals 0). also, if an IS CA is failing without throwing up a MessageBox, then perhaps it should be authored to do so...otherwise when a customer has an issue with the installation and you haven't reproduced the problem in-house, you'll have NOTHING to go on to help troubleshoot the customer issue. (or if you're a n00b trying to figure out another person's project... 😛 )

alas, i don't know much about using prerequisites, but you need to disassociate a prereq from the project, rather than simply deleting the file from which the project expects to get information on its prereqs.


Thank you so much for all of the great info. I actually figured out a few of these issues (in particular having to actually REMOVE the prereqs, not the files), but the general information is great. I feel like I'm just clicking random boxes (with a small amount of logical guess work put in), so it's nice to have some clarification. Thank you!


I have a follow up question (though it's basically 100% unrelated :)):

I have two custom actions, each one of them calls a third party exe file which installs a driver. I've got the execution order setup so that one executes "after install welcome", and the other starts after the previous exe exits (so based on the exit code). Now, the issue is that the first exe (again, these are third party applications) is a two step installer. First, it extracts a bunch of files into a temp directory, at which point (I'm assuming) it "throws" an exit code, which triggers my application to continue with the second program. But of course, the first custom action has not REALLY completed, the files have just been extracted.

So to sum up the issue, I'd like one exe to run after another, but simply using the "exit code" doesn't work because from what my limited experience can tell, the first custom action (an install exe) has two parts so even though it's not done installing, it throws an exit code after the first part which triggers the second custom action to run.

Any thoughts on this? Can I somehow tell the second custom action to wait for TWO exit codes before continuing?

I've thought about adding a third custom action, which does nothing, and just have it run when it gets the first exit code. Is this an acceptable solution?

Thanks again!
0 Kudos
Kelter
Level 10

I think you'd have to write some code to wait on the second process. If you have enough information about the process itself, you should be able to enumerate the running processes, and find the one in question and wait on it.

This is kindof a "brute force" method. I'm wondering af somebody has a solution with a little more finesse...
0 Kudos
kmitchell
Level 3

Thanks for the tips.

Unfortunately I'm not sure how I'd go about doing what you mentioned.


I know that I have two custom actions, and independently they work perfectly (you start the setup.exe file that i created in InstallShiled, click "next", select the path to install, then the custom actions kick in and the third party software/driver installs launch). After that, the installer (that is installing my application) starts back up and installs the files/etc for my application.

The problem is that one of the two third party exe files (a driver from Logitech) starts while the other custom action is running, instead of waiting.


The thing that is frustrating is that the installer was working perfectly before I added the logitech driver. I was even able to use two exe files, and they would run, one after the other, however the Logitech exe seems to throw the installer off and it allows the second custom action to fire before it is finished.
0 Kudos
Kelter
Level 10

Maybe logitec has an OEM solution for you? Perhaps they provide merge-modules to OEMs installing their driver.

If not, you'll want to write an exe to wrap the driver installer. Use the PSAPI (Process Status API) to query running processes, (EnumProcesses) then iterate through them until you find the one that gets launched by the Logitec driver installation. Calling GetProcessImageFileName() will probably get you the information you need to detect the process you care about. WaitForSingleObject can be used to wait on a process.

Any more help in that direction is beyond my experience, and beyond the scope of this forum. Speaking of which, try doing some searches in the general InstallShield forum for similar issues. i'm sure I've seen a forum thread related to this very problem.
0 Kudos