WiX - how do I refresh Edit control after file browse dialog











up vote
0
down vote

favorite












I am required to have a FileBrowseDialog during a WiX installation. I made my own custom dialog that raises the OpenFileDialog and sets the selected value in the session property (found the code here). I need a way to refresh the Edit control with the selected full path. Right now, after choosing the file, the edit control remains blank. How do I achieve this? I am not an expert in MSI or WiX.



Wix Code:



<UI>
<Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
<Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
<Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
<Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
<Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

<Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
<Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
<Publish Event="DoAction" Value="BrowseDBFile" Order="0">1</Publish>
<Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
</Control>
<Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

<Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
<Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
<Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" />
<Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
<Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
</Control>
</Dialog>
</UI>


Custom Action Code:



[CustomAction]
public static ActionResult BrowseDBFile(Session session)
{
try {
session.Log("Begin OpenFileChooser Custom Action");
var task = new Thread(() => GetFile(session));
task.SetApartmentState(ApartmentState.STA);
task.Start();
task.Join();
session.Log("End OpenFileChooser Custom Action");
} catch (Exception ex) {
session.Log("Exception occurred as Message: {0}rn StackTrace: {1}", ex.Message, ex.StackTrace);
return ActionResult.Failure;
}
return ActionResult.Success;
}

private static void GetFile(Session session)
{
OpenFileDialog fileDialog = new OpenFileDialog();
if (fileDialog.ShowDialog() == DialogResult.OK) {
session["DRUGSDBFILEPATH"] = fileDialog.FileName;
}
}


UPDATE



Found out the solution is to invoke the RESET event before performing the action associated to the BROWSE button. I also performed a PUBLISH PROPERTY after performing the custom action. Look below.



<UI>
<Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
<Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
<Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
<Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
<Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

<Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
<Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
<Publish Event="Reset" Value="1">1</Publish>
<Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
<Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
</Control>
<Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

<Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
<Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
<Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
<Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
<Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
</Control>
<Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
<Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
</Control>
</Dialog>
</UI>









share|improve this question




























    up vote
    0
    down vote

    favorite












    I am required to have a FileBrowseDialog during a WiX installation. I made my own custom dialog that raises the OpenFileDialog and sets the selected value in the session property (found the code here). I need a way to refresh the Edit control with the selected full path. Right now, after choosing the file, the edit control remains blank. How do I achieve this? I am not an expert in MSI or WiX.



    Wix Code:



    <UI>
    <Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
    <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
    <Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
    <Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
    <Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

    <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
    <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
    <Publish Event="DoAction" Value="BrowseDBFile" Order="0">1</Publish>
    <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
    </Control>
    <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

    <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
    <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
    <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" />
    <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
    <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
    </Control>
    </Dialog>
    </UI>


    Custom Action Code:



    [CustomAction]
    public static ActionResult BrowseDBFile(Session session)
    {
    try {
    session.Log("Begin OpenFileChooser Custom Action");
    var task = new Thread(() => GetFile(session));
    task.SetApartmentState(ApartmentState.STA);
    task.Start();
    task.Join();
    session.Log("End OpenFileChooser Custom Action");
    } catch (Exception ex) {
    session.Log("Exception occurred as Message: {0}rn StackTrace: {1}", ex.Message, ex.StackTrace);
    return ActionResult.Failure;
    }
    return ActionResult.Success;
    }

    private static void GetFile(Session session)
    {
    OpenFileDialog fileDialog = new OpenFileDialog();
    if (fileDialog.ShowDialog() == DialogResult.OK) {
    session["DRUGSDBFILEPATH"] = fileDialog.FileName;
    }
    }


    UPDATE



    Found out the solution is to invoke the RESET event before performing the action associated to the BROWSE button. I also performed a PUBLISH PROPERTY after performing the custom action. Look below.



    <UI>
    <Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
    <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
    <Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
    <Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
    <Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

    <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
    <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
    <Publish Event="Reset" Value="1">1</Publish>
    <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
    <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
    </Control>
    <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

    <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
    <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
    <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
    <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
    <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
    </Control>
    <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
    <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
    </Control>
    </Dialog>
    </UI>









    share|improve this question


























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I am required to have a FileBrowseDialog during a WiX installation. I made my own custom dialog that raises the OpenFileDialog and sets the selected value in the session property (found the code here). I need a way to refresh the Edit control with the selected full path. Right now, after choosing the file, the edit control remains blank. How do I achieve this? I am not an expert in MSI or WiX.



      Wix Code:



      <UI>
      <Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
      <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
      <Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
      <Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
      <Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

      <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
      <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
      <Publish Event="DoAction" Value="BrowseDBFile" Order="0">1</Publish>
      <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
      </Control>
      <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

      <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
      <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
      <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" />
      <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
      <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
      </Control>
      </Dialog>
      </UI>


      Custom Action Code:



      [CustomAction]
      public static ActionResult BrowseDBFile(Session session)
      {
      try {
      session.Log("Begin OpenFileChooser Custom Action");
      var task = new Thread(() => GetFile(session));
      task.SetApartmentState(ApartmentState.STA);
      task.Start();
      task.Join();
      session.Log("End OpenFileChooser Custom Action");
      } catch (Exception ex) {
      session.Log("Exception occurred as Message: {0}rn StackTrace: {1}", ex.Message, ex.StackTrace);
      return ActionResult.Failure;
      }
      return ActionResult.Success;
      }

      private static void GetFile(Session session)
      {
      OpenFileDialog fileDialog = new OpenFileDialog();
      if (fileDialog.ShowDialog() == DialogResult.OK) {
      session["DRUGSDBFILEPATH"] = fileDialog.FileName;
      }
      }


      UPDATE



      Found out the solution is to invoke the RESET event before performing the action associated to the BROWSE button. I also performed a PUBLISH PROPERTY after performing the custom action. Look below.



      <UI>
      <Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
      <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
      <Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
      <Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
      <Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

      <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
      <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
      <Publish Event="Reset" Value="1">1</Publish>
      <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
      <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
      </Control>
      <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

      <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
      <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
      <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
      <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
      <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
      </Control>
      <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
      <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
      </Control>
      </Dialog>
      </UI>









      share|improve this question















      I am required to have a FileBrowseDialog during a WiX installation. I made my own custom dialog that raises the OpenFileDialog and sets the selected value in the session property (found the code here). I need a way to refresh the Edit control with the selected full path. Right now, after choosing the file, the edit control remains blank. How do I achieve this? I am not an expert in MSI or WiX.



      Wix Code:



      <UI>
      <Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
      <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
      <Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
      <Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
      <Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

      <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
      <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
      <Publish Event="DoAction" Value="BrowseDBFile" Order="0">1</Publish>
      <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
      </Control>
      <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

      <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
      <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
      <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" />
      <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
      <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
      </Control>
      </Dialog>
      </UI>


      Custom Action Code:



      [CustomAction]
      public static ActionResult BrowseDBFile(Session session)
      {
      try {
      session.Log("Begin OpenFileChooser Custom Action");
      var task = new Thread(() => GetFile(session));
      task.SetApartmentState(ApartmentState.STA);
      task.Start();
      task.Join();
      session.Log("End OpenFileChooser Custom Action");
      } catch (Exception ex) {
      session.Log("Exception occurred as Message: {0}rn StackTrace: {1}", ex.Message, ex.StackTrace);
      return ActionResult.Failure;
      }
      return ActionResult.Success;
      }

      private static void GetFile(Session session)
      {
      OpenFileDialog fileDialog = new OpenFileDialog();
      if (fileDialog.ShowDialog() == DialogResult.OK) {
      session["DRUGSDBFILEPATH"] = fileDialog.FileName;
      }
      }


      UPDATE



      Found out the solution is to invoke the RESET event before performing the action associated to the BROWSE button. I also performed a PUBLISH PROPERTY after performing the custom action. Look below.



      <UI>
      <Dialog Id="DrugsDBFileBrowseDialog" Width="370" Height="270" Title="!(loc.DrugsDBFileDlg_Title)">
      <Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
      <Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
      <Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgDescription)" />
      <Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.DrugsDBFileDlgTitle)" />

      <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
      <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
      <Publish Event="Reset" Value="1">1</Publish>
      <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
      <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
      </Control>
      <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

      <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
      <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
      <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
      <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
      <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
      </Control>
      <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
      <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
      </Control>
      </Dialog>
      </UI>






      wix windows-installer wix3.11






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 8 at 17:02

























      asked Nov 7 at 22:31









      D. Bermudez

      1022618




      1022618
























          1 Answer
          1






          active

          oldest

          votes

















          up vote
          0
          down vote



          accepted

















              <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
          <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
          <Publish Event="Reset" Value="1">1</Publish>
          <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
          <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
          </Control>
          <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

          <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
          <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
          <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
          <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
          <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
          </Control>
          <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
          <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
          </Control>
          </Dialog>
          </UI>





          share|improve this answer





















            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53198893%2fwix-how-do-i-refresh-edit-control-after-file-browse-dialog%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            0
            down vote



            accepted

















                <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
            <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
            <Publish Event="Reset" Value="1">1</Publish>
            <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
            <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
            </Control>
            <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

            <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
            <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
            <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
            <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
            <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
            </Control>
            <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
            <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
            </Control>
            </Dialog>
            </UI>





            share|improve this answer

























              up vote
              0
              down vote



              accepted

















                  <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
              <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
              <Publish Event="Reset" Value="1">1</Publish>
              <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
              <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
              </Control>
              <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

              <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
              <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
              <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
              <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
              <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
              </Control>
              <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
              <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
              </Control>
              </Dialog>
              </UI>





              share|improve this answer























                up vote
                0
                down vote



                accepted







                up vote
                0
                down vote



                accepted













                    <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
                <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
                <Publish Event="Reset" Value="1">1</Publish>
                <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
                <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
                </Control>
                <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

                <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
                <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
                <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
                <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
                <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
                </Control>
                <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
                <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
                </Control>
                </Dialog>
                </UI>





                share|improve this answer



















                    <Control Type="Edit" Id="txtDrugsFilePath" Width="270" Height="15" X="22" Y="142" Property="DRUGSDBFILEPATH" Text="[DRUGSDBFILEPATH]" />
                <Control Type="PushButton" Id="btnBrowse" Width="56" Height="21" X="300" Y="139" Text="&amp;Browse" >
                <Publish Event="Reset" Value="1">1</Publish>
                <Publish Event="DoAction" Value="BrowseDBFile" Order="1"><![CDATA[1]]></Publish>
                <Publish Property="DRUGSDBFILEPATH" Value="[DRUGSDBFILEPATH]"><![CDATA[1]]></Publish>
                </Control>
                <Control Type="Text" Id="lblInstructions" Width="290" Height="15" X="26" Y="120" Text="!(loc.DrugsDBFileDlgLabelDescription)" />

                <Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
                <Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
                <Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Text="!(loc.WixUINext)" >
                <Publish Event="DoAction" Value="ValidateSelectedPath" Order="1">1</Publish>
                <Publish Event="SpawnDialog" Value="ValidationErrorDlg" Order="1000">ValidationErrorText</Publish>
                </Control>
                <Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
                <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
                </Control>
                </Dialog>
                </UI>






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Nov 13 at 20:53









                D. Bermudez

                1022618




                1022618






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.





                    Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                    Please pay close attention to the following guidance:


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53198893%2fwix-how-do-i-refresh-edit-control-after-file-browse-dialog%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    這個網誌中的熱門文章

                    Tangent Lines Diagram Along Smooth Curve

                    Yusuf al-Mu'taman ibn Hud

                    Zucchini