Windows 7, PowerShell 5
In Bruce Payette's book "Windows Powershell In Action" (2) on page 754 there is a WPF example called "Building a file search tool".
I need to modify the ComboBox
(originally a TextBox
) in the XAML by passing in PowerShell variables $pwd
and [Environment]::GetFolderPath("MyDocuments")
by using something
like:
<Label Width="100" >Path to Search</Label>
<ComboBox Name="Path" Width="324" Height="23" IsEditable="True">
<ComboBoxItem >d:\files</ComboBoxItem>
</ComboBox>
$path = $form.FindName("Path")
$path.DropDown = $pwd
Is there a way to do this please?