Click here to Skip to main content
15,921,179 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
How can i create a bitmap object from a Image control that contains an image.
Posted

try this
C#
Image objImage = Image.FromFile(Server.MapPath("myimg.jpg"));
int height = objImage.Height;//Actual image width
int width = objImage.Width;//Actual image height

Bitmap bitmapimage = new Bitmap(objImage, width, height);
 
Share this answer
 
Hi,

This post may help you
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900