Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><a href="http://www.mail-archive.com/wix-users@lists.sourceforge.net/msg05097.html">http://www.mail-archive.com/wix-users@lists.sourceforge.net/msg05097.html</a> gives an solution to republish the properties that were changed in the custom action immediately after it.</p> <p>Here is an example of how I have gotten it to work in my code:</p> <pre class="lang-xml prettyprint-override"><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"&gt; &lt;Fragment&gt; &lt;Binary Id="ConnectionStringExtension.dll" SourceFile="$(var.ConnectionStringExtension.TargetDir)$(var.ConnectionStringExtension.TargetName).CA.dll" /&gt; &lt;CustomAction Id="MyCustomAction" BinaryKey="ConnectionStringExtension.dll" DllEntry="VerifyConnectionString" Execute="immediate" /&gt; &lt;UI&gt; &lt;Dialog Id="ConnectionStringDlg" Width="370" Height="270" Title="Database Settings - [ProductName]" NoMinimize="yes"&gt; &lt;Control Id="ConnectionStringLabel" Type="Text" X="45" Y="73" Width="100" Height="15" TabSkip="no" Text="&amp;amp;Connection String:" /&gt; &lt;Control Id="ConnectionStringEdit" Type="Edit" X="45" Y="95" Width="220" Height="15" Property="CONNECTION_STRING" Text="{200}" /&gt; &lt;Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="&amp;amp;Back"&gt; &lt;/Control&gt; &lt;Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Default="yes" Text="&amp;amp;Next"&gt; &lt;Condition Action="enable"&gt;&lt;![CDATA[CONNECTION_STRING &lt;&gt; "" AND CONNECTION_STRING_VALID = "1"]]&gt;&lt;/Condition&gt; &lt;Condition Action="disable"&gt;&lt;![CDATA[CONNECTION_STRING = "" OR CONNECTION_STRING_VALID = "0"]]&gt;&lt;/Condition&gt; &lt;/Control&gt; &lt;Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="Cancel"&gt; &lt;Publish Event="SpawnDialog" Value="CancelDlg"&gt;1&lt;/Publish&gt; &lt;/Control&gt; &lt;Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="WixUI_Bmp_Banner" /&gt; &lt;Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes"&gt; &lt;Text&gt;Please enter database configuration&lt;/Text&gt; &lt;/Control&gt; &lt;Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" /&gt; &lt;Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes"&gt; &lt;Text&gt;{\WixUI_Font_Title}Database Settings&lt;/Text&gt; &lt;/Control&gt; &lt;Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" /&gt; &lt;Control Id="VerifyButton" Type="PushButton" Width="56" Height="16" X="45" Y="118" Text="Verify"&gt; &lt;Publish Event="DoAction" Value="MyCustomAction"&gt;1&lt;/Publish&gt; &lt;Publish Property="TEMP_VERIFIED" Value="[CONNECTION_STRING_VALID]"&gt;1&lt;/Publish&gt; &lt;Publish Property="CONNECTION_STRING_VALID" Value="[TEMP_VERIFIED]" /&gt; &lt;/Control&gt; &lt;/Dialog&gt; &lt;/UI&gt; &lt;/Fragment&gt; &lt;/Wix&gt; </code></pre> <p>The CustomAction sets the value of CONNECTION_STRING_VALID to either 1 or 0 depending if it is valid or not and I have defined elsewhere that by default its value is 0</p> <pre class="lang-xml prettyprint-override"><code>&lt;Property Id="CONNECTION_STRING_VALID" Value="0" /&gt; </code></pre> <p>Now when I click my verify button if the string is valid the next button is enabled</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload