Hi,
I try to read Check.ini file, which lies in Windows directory, and need to
check the value of KeyVersion, i.e., "Test". I try to write custom action
for this, but it is giving error. 

The file is:

[RegTest]
Name=Check
KeyVersion=Test

In WiX,
<Property Id="SEARCH_INI">
      <IniFileSearch Id="SearchIniFile" Type="raw" Name="Check.ini"
LongName="Check.ini" Section="RegTest" Key="KeyVersion" Field="1" />
    </Property>

 <Condition Message="You must have Check.ini file. Installation will now
abort.">
        <![CDATA[SEARCH_INI <> ""]]>
 </Condition> 
  
Also, I need to check value of KeyVersion. This code needs Value? 
If the KeyVersion is not Test, installation should abort. How to include
this?

 <CustomAction Id='CheckKey' Property='SEARCH_INI' Value='Key'
Return='ignore' />

 <InstallExecuteSequence>
        <Custom Action='CheckKey' After='InstallFinalize'>NOT Installed</Custom>
 </InstallExecuteSequence>
 
Thanks,
Ansuya



-- 
View this message in context: 
http://www.nabble.com/Condition-and-IniFileSearch-tf4251162.html#a12099336
Sent from the wix-users mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to