Hey RG
Today ill be Showing you how to control your resources images using the string of the resource
the point of this was that i can control the displayed image in picture box by selected Index from combo box and i found a solution for that some time ago and just forgot to share it with you guys
so lets get started
Things we need !
1.Drop Picture box to your Form
2.Drop Combo box to your Form
3.Drop few images in resources of your project and remember the names
Now the usage !
1.in Combo box collection type image names one after another by line down
2.double click the combo box and paste this code inside . and rename tools names to yours
[HIDE]
System.Resources.ResourceManager Resource = new global::System.Resources.ResourceManager("Your_Project_Name_Here.Properties.Resources", typeof(Your_Project_Name_Here.Properties.Resources).Assembly); object obj = Resource.GetObject(Combobox_Name_Here.GetItemText(Combobox_Name_Here.SelectedItem)); Picture_Box_Name_Here.Image = ((System.Drawing.Bitmap)(obj));
[/HIDE]
Now when selecting image string in combo box it will display the image you selected 🙂
if you need help to understand it or something feel free to PM me
Have Fun !