InstallShield Tips and Techniques

October 26, 2015

InstallShield Issue when importing Dialog into Basic MSI Projects

Filed under: Reference Materials — shieldmaster @ 6:57 pm

 

I was working on a project recently that required me to replicate one of the dialogs from one project to another – in this case a dialog with a radio selection – to let the client indicate if a Server or Workstation installation was desired. Instead of recreating the dialog, I chose the option to “Export” the dialog from one project to the target project. After the export and cleanup – my installation encountered a strange abort, after the dialogs were displayed and I selected INSTALL on the “Ready To Install” dialog the installation activity disappeared!!! No dialogs appeared, just the dead Setup/MsiExec processes running.

 

It took a week of sleuthing to uncover the problem. A WEEK of 3-4 hours each night trying to determine the problem! Finally I realized that the String table contained incorrect checksums! I had modified the string table entry while the project was not open in InstallShield but kept the checksum value the same. Apparently InstallShield does not check the String Table integrity when you open/close the project. Consequently during execution, the incorrect String Table values caused the install to abort.

 

To clarify, I am going to step thru the correct process to Export/Import a dialog – and show you what I did wrong!

 

 

Exporting the Dialog

Here is the dialog I wanted to export/import – notice the icons representing the Server/Client workstation:

 

To start the process – I right-clicked the dialog and chose “Export to Project File…” – as shown here:

 


 

Now, navigate to the InstallShield project you want to import the dialog – (Hint: it must not be open in InstallShield – if so it will be locked and you can’t import the dialog)..

 


 

Immediately you will see String Tables being shown as conflicting values – in this case I can’t correct them since they are not “Key” values – so I must Overwrite and resolve them later. Here are a couple of conflicts:

 


 


 

Resolving Icon Issues

 

The first thing you will notice will be some new files (NewBinary1,etc) in the ISM directory – they are misplaced Icons that are imported from the orginal dialog – in this case the Dialog Banner, and Client/Server icons.

 


 

To demonstrate – rename the files with BMP extension and view them as Icons:


 

Now open the SQLFinancials project that you exported the dialog into – and display the new dialog “ISI_SetupType”

 


 

 

Highlight the Server icon – and you will set it pointing to that NewBinary file. Now correctly point it to the existing icon in your directory, as shown here:

 

 


 

Now correctly point the other two icons to their icon in your directory to resolve this issue, then you can delete the NewBinary files.

 

Resolving String Table Issues

 

The string table now has entries that overwrote existing table entries – I can see this by using a tool like “BeyondCompare” to view the Before/After images of the SQLFinancials.ISM project (saved in XML format).

 

As you can see, I have the before image (Copy of SQLFinancials_B4NewDialog.ISM” on the top panel and the modified SQLFinancials.ISM on the bottom panel. Notice that “NewString1” has been overlayed with different sting values – and the checksum is different to match the new values. The same situation exists for entries “ID_STRING71” thru “ID_STRING75”.

 


 

The proper method to resolve this issue is to open the SQLFinancials project within InstallShield and follow these steps for each String table entry:

  1. Go to the new Dialog – and select the string entry “Client Workstation” and select the three dots […] to the right side of the Text entry. This opens the String Table to “NEW_STRING1”

 


 

 

  1. Copy the entry found there “{&MSSansBold8}Client Workstation”
  2. Press the + button to create a new String table – and paste that value in the field – as shown here:
  3. Repeat for each of the string table entries that were overwritten during the import of the dialog.

     


 

  1. Now Save the project in InstallShield.
  2. Open the before/after projects in BeyondCompare – and COPY each string table that was modified from the Before image to the After image. You want to ensure the entry for NEW_STRING1 in the before image is exactly like the entry in the String Table of the After project. Copy the entire line – which includes the checksum value.

 


 

Don’t manipulate the String Table outside of InstallShield

 

Now you have correctly put the String table back in sync, please don’t do what I did which caused the abort during execution. What I did was to use the BeyondCompare tool – and I copied the string value “{TahomaBold8}[ISI+PreReq2_Selection1_Title]” from the Before ISM to the After ISM for entry “NEW_STRING1”. I did not copy the corresponding checksum – this was my mistake. BAD BAD BAD L

 

Hopefully this helps you in your project development!

 

ShieldMaster

Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: