Reputation: 725
I want to extract a folder path other than an installation directory using a second folder browser dialog.
<Control Id="edtDataStoreLocation" Type="PathEdit" X="45" Y="174" Height="18" Width="220"Property="MyProperty"/>
<Control Id="btnStoreLocation" Type="PushButton" X="270" Y="175" Width="56" Height="17" Text="Browse" >
<Publish Property="SelectFolderDialog_Property" Value="MyProperty" Order="1">1</Publish>
<Publish Event="SpawnDialog" Value="SelectFolderDialog" Order="2">1</Publish>
</Control>
This throws up an error when I click OK in the browser dialog. Following is the error.
The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2727.
How can i select a folder and extract this path to MyProperty ?
Upvotes: 0
Views: 326
Reputation: 212
You can do that with custom action if you want :
var dialog = new OpenFileDialog
{
Filter = @"PFX Files|*.ipa",
Title = @"Add IPA file"
};
if (dialog.ShowDialog() == DialogResult.OK)
{
doSometh with the result;
}
Upvotes: 1