?
Solved

Wise Windows Installer v6, test for Registry value

Posted on 2010-11-26
4
Medium Priority
?
900 Views
Last Modified: 2012-05-10
I am using Wise Windows Installer v6 Professional, and need to test for the presence of a specific Registry value and abort the installation if it is not found. I am currently using the Search System option to retrieve the data from the value, which is a path that is saved to [INSTALLDIR].

I need this test becuase I need to abort the installation if a another of my installations programs has not been previously executed, which would have created and set the value that I am testing.
0
Comment
Question by:JVarco
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 40

Expert Comment

by:Vadim Rapp
ID: 34236384
ok... so what's the problem?
0
 

Author Comment

by:JVarco
ID: 34239085
If the system search suceeds, the data is retrieved from the Registry, the [INSTALLDIR] variable is updated. If the search fails, the [INSTALLDIR] variable defaults to the path set in the Product Details page. So the installation does not know the search failed, it just installs to whichever path is set in the variable.

I need to be able to determine if the Registry key or value name exists at all, or if the data in another value is the wrong data, notify the user and abort the install.

If the retrieved path data is valid, I need to be able to append additional path data to it and save it to {INSTALLDIR].

Does this help?
0
 
LVL 40

Accepted Solution

by:
Vadim Rapp earned 2000 total points
ID: 34270483
Then do your system search for another property, rather than INSTALLDIR; then analyze that property. You can create Launch Condition based on the property (go to setup editor /product). For instance, if you create system search that returns the result in MYPROPERTY, then specify launch conditition MYPROPERTY. If the search does not find the value, then MYPROPERTY will be empty, launch condition will fail, and installation will be aborted. Make sure that the action LaunchConditions is placed after AppSearch in the installation script, in both User Interface and Execute Immediate.

In order to append returned value to INSTALLDIR, go to the installation script, and insert action Set Property somewhere after LaunchConditions.
0
 
LVL 40

Expert Comment

by:Vadim Rapp
ID: 34270511
The last paragraph of the prev. comment - this should be done only in Execute Immediate, so it does not get appended twice.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Installations often have prerequisites, such as “Microsoft .Net framework is required for this product”. The usual implementation in MSI installations is system search for a particular registry setting representing the required prerequisite, followe…
With User Account Control (UAC) enabled in Windows 7, one needs to open an elevated Command Prompt in order to run scripts under administrative privileges. Although the elevated Command Prompt accomplishes the task, the question How to run as script…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question