loading a bitmap file
-
well guys, i still haven't got any reply to my dying need of the code on how to load and display and save a bitmap file. If anybody can hear and see me , please help me out. :-{
tony-yeyo
Hi,
Bitmap b = new Bitmap("C:\\MyPicture.bmp"); //Load
pictureBox.Image = b; //Display
b.Save("C:\\MyNewPicture.bmp"); //SaveThe second line assumes you have a PictureBox placed on your form/control.
-
Hi,
Bitmap b = new Bitmap("C:\\MyPicture.bmp"); //Load
pictureBox.Image = b; //Display
b.Save("C:\\MyNewPicture.bmp"); //SaveThe second line assumes you have a PictureBox placed on your form/control.
-
And you'd better learn to answer to the correct message. I'm quite sure Robert Rohde does have detailled knowledge of "some lirbary classes"...;P
Regards, mav -- Black holes are the places where god divided by 0...
-
Hi,
Bitmap b = new Bitmap("C:\\MyPicture.bmp"); //Load
pictureBox.Image = b; //Display
b.Save("C:\\MyNewPicture.bmp"); //SaveThe second line assumes you have a PictureBox placed on your form/control.
I know that it sounds stupid to ask for the whole code,but I need that just for this first time and i promise not to be like this. So can u give me the whole code on a user interface with a picture box and 3 buttons that loads, displays and saves a bitmap file. Thanks :-)
tony-yeyo
-
I know that it sounds stupid to ask for the whole code,but I need that just for this first time and i promise not to be like this. So can u give me the whole code on a user interface with a picture box and 3 buttons that loads, displays and saves a bitmap file. Thanks :-)
tony-yeyo
The code you've been given will do what you asked. The user interface to make it work is so trivial that if you can't do it, you deserve to fail your class. Giving it to you would be doing you a disservice, and would be doing an even bigger disservice to the rest of your class, who I presume have paid attention.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog
-
I know that it sounds stupid to ask for the whole code,but I need that just for this first time and i promise not to be like this. So can u give me the whole code on a user interface with a picture box and 3 buttons that loads, displays and saves a bitmap file. Thanks :-)
tony-yeyo
diddy34 wrote:
and i promise not to be like this
Too late! You already are! If you can't drag and drop a couple of controls on a form, what makes you think you'll be able to do it next time? -- modified at 7:48 Thursday 3rd August, 2006
Dave Kreskowiak Microsoft MVP - Visual Basic
-
And you'd better learn to answer to the correct message. I'm quite sure Robert Rohde does have detailled knowledge of "some lirbary classes"...;P
Regards, mav -- Black holes are the places where god divided by 0...
-
I know that it sounds stupid to ask for the whole code,but I need that just for this first time and i promise not to be like this. So can u give me the whole code on a user interface with a picture box and 3 buttons that loads, displays and saves a bitmap file. Thanks :-)
tony-yeyo