Hi all,
I add picture to my pictureBox by writing the following code : pictureBox->BackgroundImage = System::Drawing::Image::FromFile() But how would i remove that image ones i am done using it?


Thank you in advanced.

Recommended Answers

All 4 Replies

Man, I'm sorry but, do you really expect us to answer your question?

Yes i do, i cant figure out a way to do this.
When i give it a empty string it gives me a segfault.

Man, I'm sorry but, do you really expect us to answer your question?

The poster has not explicitly specified that he/she is using C++/CLI and .NET, but this is a perfectly understandable question. It's good that you're concerned about post quality, though.

@OP: Set pictureBox1->BackgroundImage = nullptr;

Thank you Jonsca,

and next time i will describe my topics and post's better.

Thank you,

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.