Saving image to file

前端 未结 4 2049
花落未央
花落未央 2020-12-05 13:08

I am working on a basic drawing application. I want the user to be able to save the contents of the image.

\"ent

4条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-05 13:59

    You can save image , save the file in your current directory application and move the file to any directory .

     Bitmap btm = new Bitmap(image.width,image.height);
        Image img = btm;
                            img.Save(@"img_" + x + ".jpg", System.Drawing.Imaging.ImageFormat.Jpeg);
                            FileInfo img__ = new FileInfo(@"img_" + x + ".jpg");
                            img__.MoveTo("myVideo\\img_" + x + ".jpg");
    

提交回复
热议问题