捕获表格图像 [英] Capture a form to image

查看:144
本文介绍了捕获表格图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有控制的一种形式,我需要抓住这种形式的形象。请帮我。谢谢你。

解决方案

  //控制CNTRL; previously声明和填充
            BMP位图=新位图(cntrl.Width,cntrl.Height);
            cntrl.DrawToBitmap(BMP,新的Rectangle(Point.Empty,bmp.Size));
 

I have a form with controls, I need capture this form to image. Please help me. Thanks.

解决方案

//Control cntrl; previously declared and populated
            Bitmap bmp = new Bitmap(cntrl.Width,cntrl.Height);
            cntrl.DrawToBitmap(bmp, new Rectangle(Point.Empty, bmp.Size));

这篇关于捕获表格图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆