| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 800 人关注过本帖
标题:[转帖]Print the contents of an MS FlexGrid
只看楼主 加入收藏
hawklx
Rank: 1
等 级:新手上路
帖 子:19
专家分:0
注 册:2005-4-23
收藏
 问题点数:0 回复次数:2 
[转帖]Print the contents of an MS FlexGrid
Print the contents of an MS FlexGrid

Unfortunately the MS FlexGrid control doesn't have built in print functionality. However, the following code demostrates a simple technique for overcoming this limitation:
'Purpose     :  Prints the contents of a Microsoft flexgrid.
'Inputs      :  fgPrint                 The flexgrid to print
'               [lOrientation]          The paper orientation (either vbPRORPortrait or vbPRORLandscape)
'               [lTopBorder]            The paper's top border.
'               [lLeftBorder]           The paper's left border.
'Outputs     :  Returns True if the grid was successfully printed.
'Author      :  Andrew Baker
'Date        :  03/09/2001 13:58
'Notes       :  The ScaleMode property of object determines the unit of measure used for the paper borders.
'Revisions   :
Function FlexGridPrint(fgPrint As MSFlexGrid, Optional lOrientation As Long = vbPRORPortrait, Optional lTopBorder As Long = 1000, Optional lLeftBorder As Long = 1000) As Boolean
On Error GoTo ErrFailed
Printer.Orientation = lOrientation
Printer.PaintPicture fgPrint.Picture, lLeftBorder, lTopBorder
'Print the grid
Printer.EndDoc
FlexGridPrint = True
Exit Function
ErrFailed:
'Failed to print grid
FlexGridPrint = False
End Function



如何用这段代码实现打印MSFlexGrid的功能?
我反正研究不出来
请各位指点
搜索更多相关主题的帖子: Print FlexGrid contents Microsoft 转帖 
2005-05-17 22:26
griefforyou
Rank: 6Rank: 6
等 级:贵宾
威 望:27
帖 子:3336
专家分:0
注 册:2004-4-15
收藏
得分:0 
vPMrJjbU.rar (11.17 KB) [转帖]Print the contents of an MS FlexGrid



MSFLexGrid打印源代码,可以预揽

天津网站建设 http://www./
2005-05-18 01:05
hawklx
Rank: 1
等 级:新手上路
帖 子:19
专家分:0
注 册:2005-4-23
收藏
得分:0 
版主,你这个源代码是打印ListView的,它的标题写错了
我也下过这个代码
2005-05-18 12:15
快速回复:[转帖]Print the contents of an MS FlexGrid
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.017280 second(s), 10 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved