Skip to content

Instantly share code, notes, and snippets.

@TScalzott
Created September 24, 2015 19:20
Show Gist options
  • Save TScalzott/467deb1152ed37274dcf to your computer and use it in GitHub Desktop.
Save TScalzott/467deb1152ed37274dcf to your computer and use it in GitHub Desktop.
# Load XAML Objects into variables
$xaml.SelectNodes("//*[@Name]") |
Where-Object { $_.Name -notlike "label_*" } |
ForEach-Object { Set-Variable -Name "WPF_$($_.Name)" -Value $Form.FindName($_.Name) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment