I have an images folder with a png in it. I would like to set a MenuItem\'s icon to that png. How do I write this in procedural code?
For those of you using vb.net, to do this you need to use this: menuItem.Icon = New Image() With {.Source = New BitmapImage(New Uri("pack://application:,,,/your_assembly;component/yourpath/Image.png"))}
menuItem.Icon = New Image() With {.Source = New BitmapImage(New Uri("pack://application:,,,/your_assembly;component/yourpath/Image.png"))}