请问各位大师我这段代码哪里错了?(0分)

  • 主题发起人 主题发起人 lf2000
  • 开始时间 开始时间
L

lf2000

Unregistered / Unconfirmed
GUEST, unregistred user!
with Printerdo

begin

// x:=pageHeight div 148 *posx;
// y:=pageWidth div 210*posy;
Printer.Canvas.Font.Name :='宋体';
Printer.Canvas.Font.Size:=8;
begin
doc;
Canvas.TextOut (x+47,y+24,curinvno.Caption );
canvas.TextOut(x+126,y+24,curinvno.caption);
canvas.TextOut (x+43,y+31,Consumer);
canvas.TextOut (x+52,y+38,Edit1.Text );
canvas.TextOut (x+30,y+50,TabItem.fieldbyname('ItemName').AsString);
canvas.TextOut (x+140,y+50,IntToStr(TabItem.fieldbyname('money').AsInteger));
canvas.TextOut (x+67,y+73,numtochi(StrToInt(Amount.caption)));
canvas.TextOut (x+125,y+80,DateToStr(now));
enddoc;
end;
 
出什么错误???请明示
 
运行的时候好象是非法存取,根本无法运行.
 
我有一个大问题:只要调用Printer.begin
Doc;
Printer.EndDoc;
中间没有任何代码,打印机也是输出很多的文本,内容就是打印机的一些内置函数
的源码!
.......begin
defineresource{userdict/Resources 2
.........%%begin
Prolog
我真的不明白阿,帮助文档里:
Ends the current print job and closes the text file variable.

procedure EndDoc;

Description

EndDoc terminates the print job (and closes the currently open Text). The print job will being printing on the printer after a call to EndDoc.
{这里的 Open Text是个什么东西?难道是被打印出来的
上述文本????}
After the application calls EndDoc, the printer begin
s printing. Use EndDoc after successfully sending a print job to the printer. If the print job isn't
successful, use the Abort method.
 
后退
顶部