Prev Previous Post   Next Post Next
Old 5th August 2003, 17:55   #1
TonyDS
Senior Member
 
Join Date: Jul 2003
Posts: 152
Thumbs up A little help would be appriciated

Before installation of My NSIS program is it possible to check the version of an exisiting exe to see if its the correct version?

I don't really mean by checking it through the Reg though, as this does not show the correct version info.

The original game is version 1.0.0.0, there are two updates for this game which will change the version to 2.0.0.1 or 2.0.0.2

I only want my NSIS program to install if the version is 2.0.0.2 otherwize you will get a message saying that you will need to update the game before you can install my NSIS program then quit

If it is the correct version it will install normally

At the momment My NSIS program checks the reg to see if the game is the correct version then installs

using this bit of script

PHP Code:
Function .onInit
ReadRegStr 
$0 HKLM "SOFTWARE\\Game software\\v1.0" "Version"
IntCmp $0 1 +++3
MessageBox MB_ICONINFORMATION
|MB_OK "WARNING: GAME needs to be updated to version 2.02."
Abort
FunctionEnd 
This is fine, but my NSIS program will install if the Games 2.01 update has been installed, which will bugger up the entire installation and make the game unplayable

See in the Reg the "version" is either 1 for the original or 2 if either update has been added.

Which makes checking the reg pointless

Like I said the only real way to check this would be from the Games EXE as this shows the true version.

Any help would be greatly appriciated plus showing me how the script should look

Thanks in advance

-Tony
TonyDS is offline   Reply With Quote
 
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump