来VB区问个ActiveReport的设置问题。

shuaialang 2010-09-17 06:45:29
是这样的

小弟公司前辈开发的一个系统,因为客户自己重组了系统和打印机。

原先的activereport报表本来是用A4打印的,现在默认就是letter纸型。
不管怎么设置,任然是letter纸型,他们用的是针式打印机的套打。

打印机属性那些能设置的地方都设置了,我觉得应该是软件报表里设置了

奇怪的是一个报表是信纸类型,但是打印正常,一个是letter类型,打印明明是一张的却显示需要26张纸才能打印出来。
而且都是一样的内容26张

我想问这个在源码里哪里设置呢。VB是没有一点代码的。

该前辈已离职。。
...全文
107 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
贝隆 2010-09-18
  • 打赏
  • 举报
回复
楼主的结帖率真是高的吓人哦
shuaialang 2010-09-18
  • 打赏
  • 举报
回复
结贴信誉第一
咸清 2010-09-17
  • 打赏
  • 举报
回复
1 Letter, 8 1/2 x 11 in
2 +A611Letter Small, 8 1/2 x 11 in
3 Tabloid, 11 x 17 in
4 Ledger, 17 x 11 in
5 Legal, 8 1/2 x 14 in
6 Statement, 5 1/2 x 8 1/2 in
7 Executive, 7 1/2 x 10 1/2 in
8 A3, 297 x 420 mm
9 A4, 210 x 297 mm
10 A4 Small, 210 x 297 mm
11 A5, 148 x 210 mm
12 B4, 250 x 354 mm
13 B5, 182 x 257 mm
14 Folio, 8 1/2 x 13 in
15 Quarto, 215 x 275 mm
16 10 x 14 in
17 11 x 17 in
18 Note, 8 1/2 x 11 in
19 Envelope #9, 3 7/8 x 8 7/8 in
20 Envelope #10, 4 1/8 x 9 1/2 in
21 Envelope #11, 4 1/2 x 10 3/8 in
22 Envelope #12, 4 1/2 x 11 in
23 Envelope #14, 5 x 11 1/2 in
24 C size sheet
25 D size sheet
26 E size sheet
27 Envelope DL, 110 x 220 mm
29 Envelope C3, 324 x 458 mm
30 Envelope C4, 229 x 324 mm
28 Envelope C5, 162 x 229 mm
31 Envelope C6, 114 x 162 mm
32 Envelope C65, 114 x 229 mm
33 Envelope B4, 250 x 353 mm
34 Envelope B5, 176 x 250 mm
35 Envelope B6, 176 x 125 mm
36 Envelope, 110 x 230 mm
37 Envelope Monarch, 3 7/8 x 7 1/2 in
38 Envelope, 3 5/8 x 6 1/2 in
39 U.S. Standard Fanfold, 14 7/8 x 11 in
40 German Standard Fanfold, 8 1/2 x 12 in
41 German Legal Fanfold, 8 1/2 x 13 in
255 User Defined
咸清 2010-09-17
  • 打赏
  • 举报
回复
'//************************************
'//以下关于获得打印纸的参数
'//************************************
Declare Function DeviceCapabilities Lib "winspool.drv" _
Alias "DeviceCapabilitiesA" (ByVal lpDeviceName As String, _
ByVal lpPort As String, ByVal iIndex As Long, lpOutput As Any, _
ByVal dev As Long) As Long

Public Declare Function AddForm Lib "winspool.drv" Alias "AddFormA" _
(ByVal hPrinter As Long, ByVal Level As Long, pForm As Byte) As Long
Public Declare Function DeleteForm Lib "winspool.drv" Alias "DeleteFormA" _
(ByVal hPrinter As Long, ByVal pFormName As String) As Long

Public Declare Function OpenPrinter Lib "winspool.drv" _
Alias "OpenPrinterA" (ByVal pPrinterName As String, _
phPrinter As Long, ByVal pDefault As Long) As Long

Public Declare Function ClosePrinter Lib "winspool.drv" _
(ByVal hPrinter As Long) As Long

Public Declare Function DocumentProperties Lib "winspool.drv" _
Alias "DocumentPropertiesA" (ByVal hwnd As Long, _
ByVal hPrinter As Long, ByVal pDeviceName As String, _
pDevModeOutput As Any, pDevModeInput As Any, ByVal fMode As Long) _
As Long
Public Declare Sub CopyMemory Lib "KERNEL32" Alias "RtlMoveMemory" _
(hpvDest As Any, hpvSource As Any, ByVal cbCopy As Long)

Public Declare Function lstrcpy Lib "KERNEL32" Alias "lstrcpyA" _
(ByVal lpString1 As String, ByRef lpString2 As Long) As Long

Public Declare Function GetForm Lib "winspool.drv" Alias "GetFormA" _
(ByVal hPrinter As Long, ByVal pFormName As String, _
ByVal Level As Long, pForm As Byte, ByVal cbBuf As Long, _
pcbNeeded As Long) As Long

Public Declare Function SetForm Lib "winspool.drv" Alias "SetFormA" _
(ByVal hPrinter As Long, ByVal pFormName As String, _
ByVal Level As Long, pForm As Byte) As Long
'这是设置打印纸的API
'---------------------------------------------------------------------

'To set the paper size in code, use the following syntax in either the ReportStart
'or PageStart events.

Dim pgCounter As Integer

Private Sub ActiveReport_PageStart()
pgCounter = pgCounter + 1
If pgCounter > 1 Then
PageSettings.PaperSize = 1 'Letter End If
End Sub

'这是设置纸张的代码
jhone99 2010-09-17
  • 打赏
  • 举报
回复
看不到你的东西,很难说出问题在哪
jhone99 2010-09-17
  • 打赏
  • 举报
回复
结帖率:104.84%

shuaialang 2010-09-17
  • 打赏
  • 举报
回复
.........没有一个人知道。。
shuaialang 2010-09-17
  • 打赏
  • 举报
回复


图片。。。

1,216

社区成员

发帖
与我相关
我的任务
社区描述
VB 数据库(包含打印,安装,报表)
社区管理员
  • 数据库(包含打印,安装,报表)社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧