国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 開發(fā) > 綜合 > 正文

收藏Code: Printing a DataGrid (Visual C#)

2024-07-21 02:19:07
字體:
供稿:網(wǎng)友

code: printing a datagrid (visual c#)
this example demonstrates printing a datagrid control.

example
private void printgrid_click(system.object sender, system.eventargs e)

printdocument1.print();

private void printdocument1_printpage(system.object sender, system.drawing.printing.printpageeventargs e)

painteventargs mypaintargs = new painteventargs(e.graphics, new rectangle(new point(0, 0), this.size));
this.invokepaint(datagrid1, mypaintargs);

compiling the code
this example requires:

a button control named printgrid with a click event handler.
a datagrid control named datagrid1.
a printdocument component named printdocument1 with a printpage event handler.
the example code replaces the existing event handlers.

robust programming
the following conditions may cause an exception:

you do not have permission to access the printer.
there is no printer installed.
security
in order to run this example, you must have permission to access the printer.

from:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cscon/html/vclrfcodeprintingdatagridvisualc.asp

作者blog:http://blog.csdn.net/ncowboy/
相關(guān)文章
what's new in the .net framework 2.0 beta
visual web developer 2005 express edition beta 1 manual setup instructions
implementing reverse proxy in squid
更改squid的錯(cuò)誤信息語言種類
.net里的哈希表和串行化
發(fā)表評論 共有條評論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 台安县| 绿春县| 泽州县| 安化县| 若羌县| 昂仁县| 金湖县| 海南省| 永兴县| 长沙县| 秭归县| 郎溪县| 浪卡子县| 宾川县| 依安县| 福海县| 靖西县| 安福县| 昆明市| 铁岭市| 诏安县| 马鞍山市| 定西市| 新田县| 三亚市| 日喀则市| 海原县| 县级市| 安宁市| 仙桃市| 舒城县| 平昌县| 常德市| 漳浦县| 赤水市| 若尔盖县| 泸水县| 瓮安县| 札达县| 陆良县| 绥棱县|