PictureBox CharacterIcon = new PictureBox();
CharacterIcon.Image = Properties.Resources.Moeyy;
I want to make the code dynamic and do something like this:
string fileName = "Moeyy";
PictureBox CharacterIcon = new PictureBox();
CharacterIcon.Image = Properties.Resources.fileName;
But I cannot do that, is there a way around it? I NEED to use the images from Resources because I can't guarantee (that if I load them from a directory) the user will have them in that same directory! I imported the Images into my Resources.resx, so Properties.Resources.Moeyy is an Image that is within the project.