I'm writing a program about trying different images in picturebox, but the image must correspond to the text. Plus it must come from "Resources" folder of the project.
this is what i want to do if the text "apple" displays to the screen then the image with a filename "apple" would also display in the picturebox..
I can do it in "if-else" like this
string word="apple"; if(word==apple) pictureBox1.Image= WindowsFormsApplication4.Properties.Resources.apple;
but What if I have a thousand images, I still think there's an easy way for this,..
i'm trying this one,,
string word=label1.Text;//label1.text changes from time to time pictureBox1.Image= WindowsFormsApplication4.Properties.Resources.word;
but I know "word" is string....It's not possible...I cannot append string to the syntax....