代码语言
.
CSharp
.
JS
Java
Asp.Net
C
MSSQL
PHP
Css
PLSQL
Python
Shell
EBS
ASP
Perl
ObjC
VB.Net
VBS
MYSQL
GO
Delphi
AS
DB2
Domino
Rails
ActionScript
Scala
代码分类
文件
系统
字符串
数据库
网络相关
图形/GUI
多媒体
算法
游戏
Jquery
Extjs
Android
HTML5
菜单
网页交互
WinForm
控件
企业应用
安全与加密
脚本/批处理
开放平台
其它
【
CSharp
】
WinForm实现抓屏
作者:
Dezai.CN
/ 发布于
2011/6/2
/
476
<div><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System.Drawing; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System.Collections; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System.ComponentModel; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System.Windows.Forms; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System.Data; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">using</span><span style="color: rgb(0,0,0)"> System.Drawing.Imaging; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span><span style="color: rgb(0,0,255)">namespace</span><span style="color: rgb(0,0,0)"> 捕获屏幕 <img id="Codehighlighter1_193_3273_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_193_3273_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedBlock.gif" alt="" /></span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_193_3273_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_193_3273_Open_Text"><span style="color: rgb(0,0,0)">{ <img id="Codehighlighter1_197_247_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_197_247_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_197_247_Closed_Text">/**/</span><span id="Codehighlighter1_197_247_Open_Text"><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"><summary></span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> Form1 的摘要说明。 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"></summary></span><span style="color: rgb(0,128,0)"> </span></span> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">public</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">class</span><span style="color: rgb(0,0,0)"> Form1 : System.Windows.Forms.Form <img id="Codehighlighter1_298_3270_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_298_3270_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_298_3270_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_298_3270_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">private</span><span style="color: rgb(0,0,0)"> System.Windows.Forms.Button button1; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">private</span><span style="color: rgb(0,0,0)"> System.Windows.Forms.SaveFileDialog saveFileDialog1; <img id="Codehighlighter1_415_464_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_415_464_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_415_464_Closed_Text">/**/</span><span id="Codehighlighter1_415_464_Open_Text"><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"><summary></span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> 必需的设计器变量。 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"></summary></span><span style="color: rgb(0,128,0)"> </span></span> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">private</span><span style="color: rgb(0,0,0)"> System.ComponentModel.Container components </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">null</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">public</span><span style="color: rgb(0,0,0)"> Form1() <img id="Codehighlighter1_548_685_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_548_685_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_548_685_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_548_685_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> Windows 窗体设计器支持所必需的 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> InitializeComponent(); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> TODO: 在 InitializeComponent 调用后添加任何构造函数代码 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /></span><span style="color: rgb(0,0,0)"> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img id="Codehighlighter1_691_743_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_691_743_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_691_743_Closed_Text">/**/</span><span id="Codehighlighter1_691_743_Open_Text"><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"><summary></span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> 清理所有正在使用的资源。 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"></summary></span><span style="color: rgb(0,128,0)"> </span></span> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">protected</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">override</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">void</span><span style="color: rgb(0,0,0)"> Dispose( </span><span style="color: rgb(0,0,255)">bool</span><span style="color: rgb(0,0,0)"> disposing ) <img id="Codehighlighter1_799_938_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_799_938_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_799_938_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_799_938_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">if</span><span style="color: rgb(0,0,0)">( disposing ) <img id="Codehighlighter1_825_902_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_825_902_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_825_902_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_825_902_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">if</span><span style="color: rgb(0,0,0)"> (components </span><span style="color: rgb(0,0,0)">!=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">null</span><span style="color: rgb(0,0,0)">) <img id="Codehighlighter1_861_896_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_861_896_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_861_896_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_861_896_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> components.Dispose(); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">base</span><span style="color: rgb(0,0,0)">.Dispose( disposing ); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img id="Codehighlighter1_944_1877_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /><img style="display: none" id="Codehighlighter1_944_1877_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_944_1877_Closed_Text">Windows 窗体设计器生成的代码</span><span style="display: none" id="Codehighlighter1_944_1877_Open_Text"><span style="color: rgb(0,0,255)">#region</span><span style="color: rgb(0,0,0)"> Windows 窗体设计器生成的代码 </span><span style="color: rgb(0,0,0)"> <img id="Codehighlighter1_974_1053_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_974_1053_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_974_1053_Closed_Text">/**/</span><span id="Codehighlighter1_974_1053_Open_Text"><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"><summary></span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> 设计器支持所需的方法 - 不要使用代码编辑器修改 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> 此方法的内容。 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"></summary></span><span style="color: rgb(0,128,0)"> </span></span> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">private</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">void</span><span style="color: rgb(0,0,0)"> InitializeComponent() <img id="Codehighlighter1_1094_1863_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_1094_1863_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_1094_1863_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_1094_1863_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1 </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> System.Windows.Forms.Button(); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.saveFileDialog1 </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> System.Windows.Forms.SaveFileDialog(); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.SuspendLayout(); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> button1 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1.Location </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> System.Drawing.Point(</span><span style="color: rgb(0,0,0)">96</span><span style="color: rgb(0,0,0)">, </span><span style="color: rgb(0,0,0)">192</span><span style="color: rgb(0,0,0)">); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1.Name </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">button1</span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1.TabIndex </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)">0</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1.Text </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">截取屏幕</span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1.Click </span><span style="color: rgb(0,0,0)">+=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> System.EventHandler(</span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1_Click); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> saveFileDialog1 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.saveFileDialog1.Filter </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">JPG文件|*.Jpg</span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> Form1 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.AutoScaleBaseSize </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> System.Drawing.Size(</span><span style="color: rgb(0,0,0)">6</span><span style="color: rgb(0,0,0)">, </span><span style="color: rgb(0,0,0)">14</span><span style="color: rgb(0,0,0)">); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.ClientSize </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> System.Drawing.Size(</span><span style="color: rgb(0,0,0)">292</span><span style="color: rgb(0,0,0)">, </span><span style="color: rgb(0,0,0)">273</span><span style="color: rgb(0,0,0)">); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.Controls.Add(</span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.button1); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.Name </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">Form1</span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.Text </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">C#捕获当前屏幕!</span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.ResumeLayout(</span><span style="color: rgb(0,0,255)">false</span><span style="color: rgb(0,0,0)">); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> </span><span style="color: rgb(0,0,255)">#endregion</span></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img id="Codehighlighter1_1883_1933_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_1883_1933_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_1883_1933_Closed_Text">/**/</span><span id="Codehighlighter1_1883_1933_Open_Text"><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"><summary></span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> 应用程序的主入口点。 <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> </span><span style="color: rgb(128,128,128)">///</span><span style="color: rgb(0,128,0)"> </span><span style="color: rgb(128,128,128)"></summary></span><span style="color: rgb(0,128,0)"> </span></span> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /><span style="color: rgb(0,0,0)"> [STAThread] <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">static</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">void</span><span style="color: rgb(0,0,0)"> Main() <img id="Codehighlighter1_1973_2012_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_1973_2012_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_1973_2012_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_1973_2012_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> Application.Run(</span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> Form1()); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">声明一个API函数 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> [ System.Runtime.InteropServices.DllImportAttribute ( </span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)">gdi32.dll</span><span style="color: rgb(0,0,0)">"</span><span style="color: rgb(0,0,0)"> ) ] <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">private</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">static</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">extern</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">bool</span><span style="color: rgb(0,0,0)"> BitBlt <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> ( <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> IntPtr hdcDest , </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> 目标 DC的句柄 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">int</span><span style="color: rgb(0,0,0)"> nXDest , <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">int</span><span style="color: rgb(0,0,0)"> nYDest , <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">int</span><span style="color: rgb(0,0,0)"> nWidth , <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">int</span><span style="color: rgb(0,0,0)"> nHeight , <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> IntPtr hdcSrc , </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> 源DC的句柄 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">int</span><span style="color: rgb(0,0,0)"> nXSrc , <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">int</span><span style="color: rgb(0,0,0)"> nYSrc , <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> System.Int32 dwRop </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)"> 光栅的处理数值 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> ); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,0,255)">private</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">void</span><span style="color: rgb(0,0,0)"> button1_Click(</span><span style="color: rgb(0,0,255)">object</span><span style="color: rgb(0,0,0)"> sender, System.EventArgs e) <img id="Codehighlighter1_2420_3266_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_2420_3266_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_2420_3266_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_2420_3266_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">获得当前屏幕的大小 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> Rectangle rect </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> Rectangle ( ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">获得当前屏幕的大小,通过名字空间"System.Windows.Forms"中的"Screen"类的GetWorkingArea()方法 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> rect </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> Screen.GetWorkingArea ( </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)"> ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">创建一个以当前屏幕为模板的图象--获得当前屏幕的graphic对象 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> Graphics g1 </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">this</span><span style="color: rgb(0,0,0)">.CreateGraphics ( ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">创建以屏幕大小为标准的位图 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> Image MyImage </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">new</span><span style="color: rgb(0,0,0)"> Bitmap ( rect.Width , rect.Height , g1 ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> Graphics g2 </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> Graphics.FromImage ( MyImage ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">得到屏幕的DC </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> IntPtr dc1 </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> g1.GetHdc ( ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">得到Bitmap的DC </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> IntPtr dc2 </span><span style="color: rgb(0,0,0)">=</span><span style="color: rgb(0,0,0)"> g2.GetHdc ( ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">调用此API函数,实现屏幕捕获 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> BitBlt ( dc2 , </span><span style="color: rgb(0,0,0)">0</span><span style="color: rgb(0,0,0)"> , </span><span style="color: rgb(0,0,0)">0</span><span style="color: rgb(0,0,0)"> , rect.Width , rect.Height , dc1 , </span><span style="color: rgb(0,0,0)">0</span><span style="color: rgb(0,0,0)"> , </span><span style="color: rgb(0,0,0)">0</span><span style="color: rgb(0,0,0)"> , </span><span style="color: rgb(0,0,0)">13369376</span><span style="color: rgb(0,0,0)"> ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">释放掉屏幕的DC </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> g1.ReleaseHdc ( dc1 ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">释放掉Bitmap的DC </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> g2.ReleaseHdc ( dc2 ) ; <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> </span><span style="color: rgb(0,128,0)">//</span><span style="color: rgb(0,128,0)">以JPG文件格式来保存 </span><span style="color: rgb(0,128,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /></span><span style="color: rgb(0,0,0)"> </span><span style="color: rgb(0,0,255)">if</span><span style="color: rgb(0,0,0)"> (saveFileDialog1.ShowDialog() </span><span style="color: rgb(0,0,0)">==</span><span style="color: rgb(0,0,0)"> DialogResult.OK) <img id="Codehighlighter1_3190_3260_Open_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_3190_3260_Closed_Image" align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ContractedSubBlock.gif" alt="" /> </span><span style="border-bottom: rgb(128,128,128) 1px solid; border-left: rgb(128,128,128) 1px solid; background-color: rgb(255,255,255); display: none; border-top: rgb(128,128,128) 1px solid; border-right: rgb(128,128,128) 1px solid" id="Codehighlighter1_3190_3260_Closed_Text"><img src="http://www.cnblogs.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_3190_3260_Open_Text"><span style="color: rgb(0,0,0)">{ <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> MyImage.Save( @saveFileDialog1.FileName,ImageFormat.Jpeg); <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif" alt="" /> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" /> }</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockEnd.gif" alt="" />}</span></span><span style="color: rgb(0,0,0)"> <img align="top" src="http://www.cnblogs.com/Images/OutliningIndicators/None.gif" alt="" /></span></div>
试试其它关键字
抓屏
同语言下
.
文件IO 操作类库
.
Check图片类型[JPEG(.jpg 、.jpeg),TIF,GIF,BMP,PNG,P
.
机器名和IP取得(IPV4 IPV6)
.
Tiff转换Bitmap
.
linqHelper
.
MadieHelper.cs
.
RegHelper.cs
.
如果关闭一个窗体后激活另一个窗体的事件或方法
.
创建日志通用类
.
串口辅助开发类
可能有用的
.
C#实现的html内容截取
.
List 切割成几份 工具类
.
SQL查询 多列合并成一行用逗号隔开
.
一行一行读取txt的内容
.
C#动态修改文件夹名称(FSO实现,不移动文件)
.
c# 移动文件或文件夹
.
c#图片添加水印
.
Java PDF转换成图片并输出给前台展示
.
网站后台修改图片尺寸代码
.
处理大图片在缩略图时的展示
Dezai.CN
贡献的其它代码
(
4037
)
.
多线程Socket服务器模块
.
生成随机密码
.
清除浮动样式
.
弹出窗口居中
.
抓取url的函数
.
使用base HTTP验证
.
div模拟iframe嵌入效果
.
通过header转向的方法
.
Session操作类
.
执行sqlite输入插入操作后获得自动编号的ID
Copyright © 2004 - 2024 dezai.cn. All Rights Reserved
站长博客
粤ICP备13059550号-3