Property values and conditions
Can someone please explain how property values and conditions work? I am using WPS 7 and cannot seem to make sense of this. It seemed so simple until I started to actually do it. What I want it this:
Condition that is based off of a file existing. This file is SQLNCLI.DRV (SQL Native Client driver) in %SYSTEM32%. If this file exists, it should return a value to my property SQLEXISTS. I believe the value is the folder that the file is located in. I have search depth set to 0 levels. I do not know if this is a secure (I think that is the term) property. I know that public needs to be all caps.
If this file is not installed, I want the install to halt. In condition table, I entered everything I could think of and cannot make this work.
conditions I have tried:
SQLEXISTS=Null
SQLEXISTS="C:\WINDOWS\SYSTEM32\"
SQLEXISTS~=""
I know this will be an easy answer. I am more concerned with learning the logic behind this. How would I then create a way of installing the SQL driver MSI as a prerequisite?
Jimm
Condition that is based off of a file existing. This file is SQLNCLI.DRV (SQL Native Client driver) in %SYSTEM32%. If this file exists, it should return a value to my property SQLEXISTS. I believe the value is the folder that the file is located in. I have search depth set to 0 levels. I do not know if this is a secure (I think that is the term) property. I know that public needs to be all caps.
If this file is not installed, I want the install to halt. In condition table, I entered everything I could think of and cannot make this work.
conditions I have tried:
SQLEXISTS=Null
SQLEXISTS="C:\WINDOWS\SYSTEM32\"
SQLEXISTS~=""
I know this will be an easy answer. I am more concerned with learning the logic behind this. How would I then create a way of installing the SQL driver MSI as a prerequisite?
Jimm
0 Comments
[ + ] Show comments
Answers (2)
Please log in to answer
Posted by:
jmcfadyen
16 years ago
theres a number of different conditions available.
you have launch conditions
component conditions
feature conditions
and the condition table.
i think the most suitable in this situation is a launch condition.
Launch conditions are used to terminate the installation should a specific condition exist and or not exist.
The simplest way to determine if a file exsits is to use the app search function.
App search can be used to look for a files existance, read registry and a number of other useful things which really aid in making an application more dynamic. This is a very powerful feature and often under utilised.
So for your case I would use appsearch to lookup the files existance and use that to set a PROPERTY.
from there set a Launch condition based on that properties existance.
Component conditions are used to stop a component from being installed based on a condition. So in your case you could stop FILEA being installed if FILEB was not present.
Now the condition table is a completely different ball game and definately not what you want in this case. (you mentioned you are using it)
The condition table is used to modify the FEATURELEVEL of a feature. The FEATURELEVEL is compared against the INSTALLLEVEL of an application. If the FEATURELEVEL is lower than the INSTALL level then a FEATURE will be set to install.
As such you use conditions to modify the FEATURELEVEL which dynamically determines if a feature would be installed.
An example might be..
Use appsearch to check if SQL.EXE exists. If that file exists set a PROPERTY to SQLEXISTS.
then you would use the condition table to modify the FEATURELEVEL of the SQLFEATURE to a value lower than INSTALLLEVEL to dynamically install the SQLFEATURE because SQL.EXE exists.
hope this makes sense.
enjoy .
you have launch conditions
component conditions
feature conditions
and the condition table.
i think the most suitable in this situation is a launch condition.
Launch conditions are used to terminate the installation should a specific condition exist and or not exist.
The simplest way to determine if a file exsits is to use the app search function.
App search can be used to look for a files existance, read registry and a number of other useful things which really aid in making an application more dynamic. This is a very powerful feature and often under utilised.
So for your case I would use appsearch to lookup the files existance and use that to set a PROPERTY.
from there set a Launch condition based on that properties existance.
Component conditions are used to stop a component from being installed based on a condition. So in your case you could stop FILEA being installed if FILEB was not present.
Now the condition table is a completely different ball game and definately not what you want in this case. (you mentioned you are using it)
The condition table is used to modify the FEATURELEVEL of a feature. The FEATURELEVEL is compared against the INSTALLLEVEL of an application. If the FEATURELEVEL is lower than the INSTALL level then a FEATURE will be set to install.
As such you use conditions to modify the FEATURELEVEL which dynamically determines if a feature would be installed.
An example might be..
Use appsearch to check if SQL.EXE exists. If that file exists set a PROPERTY to SQLEXISTS.
then you would use the condition table to modify the FEATURELEVEL of the SQLFEATURE to a value lower than INSTALLLEVEL to dynamically install the SQLFEATURE because SQL.EXE exists.
hope this makes sense.
enjoy .
Posted by:
anonymous_9363
16 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.