Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Checking for Previous Install


5 replies to this topic

cherukus

cherukus
  • Members
  • 68 posts

Posted 19 February 2004 - 21:52

We have 2 installs, one Application was developed using C++ and the script for this App was developed using InstallShield Professional.
We have another Application which was developed using C# and for this App the Install was developed using InstallShield Developer.

What I want to do is : When they are trying to install C# version of install, we want to see if the user has C++ version of install on his m/c and find out the location and display the location path and abort the new install if he is trying to install onto the same location.

I am not quite sure how I could do this. I would really appreciate any ideas.

Cheers.

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 20 February 2004 - 08:10

You could search the registry for the location of the old version, if yur old setup stored it somewhere. At least you can detect the older version by looking at the Uninstall registry key.

cherukus

cherukus
  • Members
  • 68 posts

Posted 20 February 2004 - 16:05

Can you suggest on how I should search in the Regsitry ?

cherukus

cherukus
  • Members
  • 68 posts

Posted 24 February 2004 - 17:14

Can anyone help here...Thanks.

hteichert

hteichert
  • Members
  • 158 posts

Posted 25 February 2004 - 12:45

Searching for Files, Registry Entries etc. is done with Windows Installer by the Standard Action AppSearch. For your specific needs, please look into the Windows Installer SDK documentation. There's a special chapter about "Searching for Existing Applications, Files, Registry Entries or .ini File Entries"
h.teichert-ott

grantmi

grantmi
  • Members
  • 8 posts

Posted 27 February 2004 - 11:18

What you are trying to do is very similar to me but it does not seem to work for my project.

You could try the same think and see if you are more lucky!

System Search on Registry key
If an old product is installed I don't want to install my new one.

If an old product is installed the following key is in the registry:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{42020FA9-9027-11D0-B29B-00A024A53DE6}

So I setup a Sytem Search:
I choose Registry Entry that contains other data.
Registry Root = "HKEY_LOCAL_MACHINE"
Registry Key = "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{42020FA9-9027-11D0-B29B-00A024A53DE6}"
I store it in Property = "INSTRON_OLD_CONSOLE"
I don't enter a Registry Value so I am searching for "(Default)"

Then I setup the following Install Condition in General Information - Product Properties:

NOT INSTRON_OLD_CONSOLE

with Message "An old version of Console is installed"

When I test my installation it always runs even when the registry key is there.

Can you tell me what I am doing wrong?

I tried both defining INSTRON_OLD_CONSOLE in the Property Manager and not defining it. This seemed to make no difference.
Does it make a difference if you enter it into Property Manager or not?

PS. I used to look for a file in a system search and set the INSTRON_OLD_CONSOLE property and had the same Install Condition and this seemed to work!
But checking the registry entry is a much more certain way to see if an old product is installed, so I deleted the Sytem search for the file and created one to search the registry, but it just doesn't seem to work.

Any help gladly appreciated!
Cheers Mike