This is the error message I am getting: "On Preload, Line 70: Attempt to compare number with string".
I am trying to work out the logic so an Update button is disabled if the program has never been installed. Also the Update button must be enabled if installed program has a lower version than the one on the CD.
Here is the relevant code I have so far:
Note:Code:version2 = 0000 version2 = INIFile.GetValue(mainpath.."\\myapp.ini", "program", "version"); appinstalled = File.DoesExist(mainpath.."\\MyApp.exe"); Button.SetEnabled("update", false); if version1 > version2 and appinstalled then Button.SetEnabled("update", true); end
"mainpath" contains the path to the application, its value will be NIL in new installations because the program path is read from a local INI file when program is installed.
The error does not come up after first version of program is already installed.

