高手请进!!!高分送出
wkzjl 2003-04-04 02:41:33 下面是程序的原代码
---------------------------------------------------------------
Pinfo:pPRINTERINFO2;
pprt:Cardinal;
b:PDWORD;
a:Integer;
begin
a:=3000;
Pinfo:=AllocMem(a);
b:=AllocMem(1000);
// 打开打印机
if OpenPrinter('Star AR-3200+',pprt,nil ) then
begin
// 得到当前打印机信息
if GetPrinter(pprt,2,Pinfo,a,b) then
ShowMessage(Pinfo.pPrinterName+' Status--'+IntToStr(Pinfo.Status));
// 关闭打印机
ClosePrinter(pprt);
end;
FreeMem(Pinfo);
FreeMem(b);
end;
---------------------------------------------------------------------
为什么我得到的Status值总是0;
在线等待!!!!!!!!!!!