Jul 16, 2021
06:48 AM
We have an Installscript MSI project type installer. This installer has a SQL connection (SQL Object) and it executes database scripts during the installation process. This installer supports DB connection to a remote SQL Server database server. We reply on Installshield's the schema numbers to conditionally execute the SQL Scripts. We are running into issues during upgrading installation. When running the upgrading installer, the installer does not skip the SQL scripts with lower schema numbers. It fails to detect the schema number in the target database. Here is the Log message: 1: Attempting to execute SQL scripts... 1: Determining if the SQL script 'CreateDB.sql' will be executed... 1: The SQL script will be executed because no schema version is found on the target database. It incorrectly executes the SQL Scripts which should be skipped and It generates duplicate schema numbers in [InstallShield ] table. Is this an Installshield issue? what is the best way to resolve this issue?
... View more
Labels
- Labels:
-
InstallShield
-
InstallShield 2019
Oct 12, 2020
02:46 PM
what is the solution for your Error 1303 issue? I am having the same error.
... View more
Sep 17, 2020
11:06 AM
I have a Installscript MSI project. I have a function (see below) in the Script to query database and return a value. This function worked fine in our last released installer which was developed in Installshield 2016. This year, we upgraded Installshield 2016 to Installshield 2019 and then this function stopped working at the following line: // Use the recordset to see if the database exists pADORecordSetObj.Open(sSQL); What can be the cause of this issue? How to catch the exception and get more details on the exception? //********************************************************** function STRING GetDMLANValue(sServerName, sDBName, sDriver) OBJECT pADOConnObj, pADORecordSetObj; STRING sConnString, sSQL, sLine, sDatabase, sLANValue, sError; begin sConnString = CreateConnectionStringIntegrated(sServerName, sDriver, sDBName); //the sConnString is: "Provider=sqloledb;server=(local)\MyDBInstance;database=MyDB;Trusted_connection=Yes;Integrated Security=SSPI"; //the connection string has not changed //MessageBox (sConnString, INFORMATION); // Create the SQL string to retrieve the database if it exists sSQL = "SELECT Value FROM [dbo].[APOCDMSYSCONFIGVALUE] WHERE NAME='Language'"; try // Create ADO Connection Object to connect to the SQL server set pADOConnObj = CreateObject(ADODB.Connection); // Open the ADO Connection pADOConnObj.Open(sConnString); // Create ADO Recordset object for the return set pADORecordSetObj = CreateObject(ADODB.Recordset); // Set some ADO Recordset properties pADORecordSetObj.CursorType = 3; pADORecordSetObj.ActiveConnection = pADOConnObj; // Use the recordset to see if the database exists pADORecordSetObj.Open(sSQL); if (pADORecordSetObj.RecordCount = 1) then sLANValue = pADORecordSetObj.Fields(0); else sLANValue = ""; endif; catch // nothing MessageBox ("Cannot retrieve database record: " , INFORMATION); endcatch; return sLANValue; end;
... View more
Labels
- Labels:
-
InstallShield 2019
Jul 27, 2020
02:46 PM
I have a product. The installation is InstallScript MSI type. This produce has two release versions: Ver 1, Product Code is A, Upgrade code is B Ver 2, Product Code is C, Upgrade code is B. In Ver 1, it supported operating system AA, BB. In Ver 2, the requirement is to support OS AA, BB, CC for upgrading from Ver1; For new installation, it should only support operating system CC. So I need to validate the operating system based on the installation mode (upgrading or fresh new install.) If it is fresh installation, the installer will stop user if it is operating system AA or BB. What is the best way to do this? What is the right way to detect if the Ver 1 is installed, which has different Product code than the current Version?
... View more
Labels
- Labels:
-
InstallShield
-
InstallShield 2019
Jul 19, 2019
08:02 AM
Thank you. This works.
... View more
Jul 18, 2019
01:38 PM
Thank you @banna_k The challenge for me is that these Batch files are copied to [INSTALLDIR] which is definded as [ProgramFiles64Folder]\subfolder . I want to use the following function to launch the Batch files, but I am not sure if I can construct the sLangFileFullPath like the following? sLangFileFullPath = [ProgramFiles64Folder] + "\\French.bat"; LaunchAppAndWait(sLangFileFullPath , "abc", LAAW_OPTION_WAIT_INCL_CHILD);
... View more
Jul 18, 2019
09:44 AM
I have a InstallScript MSI project. The Installation supports multiple languages. So at the end of the installation, the installer needs to run a batch file which is corresponding to the user selected language. For example if user selected French in the language dialog, the batch file French.bat will be executed; If user selects English, the English.bat will be executed. 1) What is the best way to do this? 2) I treid to create a Custom Action with the type of Launch EXE and set the Batch file name as the parameter for the cmd.exe . In this case, I need to use SELECTED_LANGUAGE as the condition for running the Custom Action. I tried the following condition: (SELECTED_LANGUAGE=ISLANG_FRENCH_STANDARD) AND (REMOVE<>"ALL") AND (NOT INSTALLED) AND (NOT UPGRADINGPRODUCTCODE) However, the cmd.exe is called when non French language is selected. It looks like SELECTED_LANGUAGE=ISLANG_FRENCH_STANDARD does not work in custom actions. I verified the SELECTED_LANGUAGE in Installscript and it is French in this test case. Can SELECTED_LANGUAGE be used as a condition in Custom Action? and how? Thank you.
... View more
Labels
- Labels:
-
InstallShield 2016 Premier
Jul 09, 2019
10:47 AM
Agshah, Your observation is correct. I just tested the behavior of setting and retrieving a public property and I see the same behavior. However, the global property (the flag) can be set in function OnFirstUIBefore() and be used in Custom Actions. In my project, I set a global property (a flag) a new value in the OnFirstUIBefore(), then I use this flag as the condition to drive the behavior of a Custom Action. This approach worked for me. There are quite a lot of types for defining Custom Actions such as SetDirectory, SetProperty, calling functions from VBScript and etc. I am thinking that the SetProperty custom action might be meant to set a new value to a Global Property session wide but I did not try it. You may explore the Custom Actions to see if you can get what you desired functionality done.
... View more
Jul 08, 2019
02:35 PM
Hello Jenifer, I have two Directories defined in the Directory table: MY_INSTALL_DIR1, MY_INSTALL_DIR2. Based on the condition, I want to set MY_INSTALL_DIR1 to be MY_INSTALL_DIR2. I cannot hard code the MY_INSTALL_DIR2 because it is a sub folder under /Program Files. I tried the following two ways but neither worked: Option 1) TextSubSetValue("<MY_INSTALL_DIR1>","<MY_INSTALL_DIR2>", TRUE ); Option 2) MsiGetProperty(ISMSI_HANDLE, "MY_INSTALL_DIR2", szValueBuf4, cchValueBuf); MsiSetProperty(ISMSI_HANDLE, "MY_INSTALL_DIR1", szValueBuf4); How to really set MY_INSTALL_DIR1 to be MY_INSTALL_DIR2 in InstallScript? What is the relationship between Property object and Directory object? How to assign a Directory value to a Property?
... View more
Jul 08, 2019
02:01 PM
Thank you for your help. The link shows me how to set /get a property, which is very useful. I also need to know how to use Directory in InstallScript. Here is what I want to achieve. I created two Directories in the Directory table: MY_INSTALL_DIR1, MY_INSTALL_DIR2. I need to dynamically set the MY_INSTALL_DIR1 to be MY_INSTALL_DIR2. I cannot hard code the path for MY_INSTALL_DIR2 because this folder should be a sub folder under the "/Program Files" folder. How can I dynamically set MY_INSTALL_DIR1 to be MY_INSTALL_DIR2?
... View more
Jul 08, 2019
12:33 PM
It seems that there are two ways to set a property: MsiSetProperty(ISMSI_HANDLE, "IS_UPGRADE_INSTALL", "2"); // 1: New Install; 2: Upgrade TextSubSetValue("<IS_UPGRADE_INSTALL>","2", TRUE ); What are the difference between these two? How to display a property in a message box?
... View more
Jul 08, 2019
10:06 AM
Hello Jenifer, Thank you very much for these information. It is very cool. I will dig into it. I am sure that I will have a few more questions later.
... View more
Jul 02, 2019
07:17 PM
when you say "we had to global variables instead of MSI properties..", what do you mean by global variables? how to create global variables? I am having the same problem like this post. I am trying to find a solution for creating a "global flag" and use this flag in InstallScript.
... View more
Jul 02, 2019
07:04 PM
May you please show us an example how to set and get the value of a public property in InstallScript's event in InstallScript MSI project?
... View more
Jul 02, 2019
05:14 PM
I inherited an InstallScript MSI Project. I do not have much knowledge in Installshield. I created two Public Properties in Behavior and Logic/Property Manager: IS_UPGRADE_INSTALL value is 1 PSWEBSITENUMBER value is 0. I also created two new Directories in Additional Tool/Direct Editor/Directory table: PS_PF64_APOC_WORLD : path to folder A PS_IIS_WEB: path to folder B I would like to use these properties and directories in the OnBegin() event of the Script. I put the following code in OnBegin(). but the syntax seems all wrong. I could not find good reference or example on how to use the Properties and Directories in code. Would someone please help me to correct the syntax in these code: function OnBegin() BOOL bInstalled; begin MsiSetProperty(ISMSI_HANDLE, "IS_UPGRADE_INSTALL", "2"); // try to set 2 to IS_UPGRADE_INSTALL property MessageBox("<IS_UPGRADE_INSTALL>", WARNING); //try to display the value of IS_UPGRADE_INSTALL if ("<IS_UPGRADE_INSTALL>" = "2") then //try to check the value MsiSetProperty(ISMSI_HANDLE, "PSWEBSITENUMBER", "3"); // try to set 3 to PSWEBSITENUMBER FeatureSetTarget(MEDIA, "<PS_PF64_APOC_WORLD>", "<PS_IIS_WEB>"); //try to set the PS_IIS_WEB value to PS_PF64_APOC_WORLD so PS_PF64_APOC_WORLD will point to the folder of PS_IIS_WEB endif; MessageBox("<PS_PF64_APOC_WORLD>", WARNING); // try to display the directory end;
... View more
Labels
- Labels:
-
InstallShield 2016 Premier
Latest posts by AceBear
Subject | Views | Posted |
---|---|---|
193 | Jul 16, 2021 06:48 AM | |
850 | Oct 12, 2020 02:46 PM | |
926 | Sep 17, 2020 11:06 AM | |
353 | Jul 27, 2020 02:46 PM | |
1802 | Jul 19, 2019 08:02 AM | |
1817 | Jul 18, 2019 01:38 PM | |
1826 | Jul 18, 2019 09:44 AM | |
4272 | Jul 09, 2019 10:47 AM | |
3357 | Jul 08, 2019 02:35 PM | |
1928 | Jul 08, 2019 02:01 PM |
Activity Feed
- Posted Installer cannot detect the schema numbers in a remote database on InstallShield Forum. Jul 16, 2021 06:48 AM
- Posted Re: Prompted to run as admin...but I am! on InstallShield Forum. Oct 12, 2020 02:46 PM
- Posted ADODB.RECORD Set stopped working in Installshield 2019 on InstallShield Forum. Sep 17, 2020 11:06 AM
- Posted How to support different operating systems in upgrading and new install? on InstallShield Forum. Jul 27, 2020 02:46 PM
- Posted Re: How to use SELECTED_LANGUAGE as a condition in Custom Action on InstallShield Forum. Jul 19, 2019 08:02 AM
- Posted Re: How to use SELECTED_LANGUAGE as a condition in Custom Action on InstallShield Forum. Jul 18, 2019 01:38 PM
- Posted How to use SELECTED_LANGUAGE as a condition in Custom Action on InstallShield Forum. Jul 18, 2019 09:44 AM
- Posted Re: MsiGetProperty and MsiSetProperty help on InstallShield Forum. Jul 09, 2019 10:47 AM
- Posted Re: How to install a web application to different websites in IIS based on a condition on InstallShield Forum. Jul 08, 2019 02:35 PM
- Posted Re: How to use public Property and Directory in script code? on InstallShield Forum. Jul 08, 2019 02:01 PM
- Posted Re: How to install a web application to different websites in IIS based on a condition on InstallShield Forum. Jul 08, 2019 12:33 PM
- Posted Re: How to install a web application to different websites in IIS based on a condition on InstallShield Forum. Jul 08, 2019 10:06 AM
- Posted Re: MsiGetProperty and MsiSetProperty help on InstallShield Forum. Jul 02, 2019 07:17 PM
- Posted Re: Differences Between A Public And Private Property on InstallShield Knowledge Base. Jul 02, 2019 07:04 PM
- Posted How to use public Property and Directory in script code? on InstallShield Forum. Jul 02, 2019 05:14 PM
- Posted Re: How to set the web app's site number to a public property? on InstallShield Forum. Jul 02, 2019 09:45 AM
- Kudoed Re: How to set the web app's site number to a public property? for banna_k. Jul 02, 2019 09:44 AM
- Posted How to set the web app's site number to a public property? on InstallShield Forum. Jul 01, 2019 05:50 PM
- Posted Re: How to install a web application to different websites in IIS based on a condition on InstallShield Forum. Jul 01, 2019 10:10 AM
- Posted How to install a web application to different websites in IIS based on a condition on InstallShield Forum. Jun 26, 2019 03:42 PM