This is a code,
The function GetPrinterStatus: byte;
Asm
MOV DX, $379;
IN AL, DX;
end;
//get a printer error
The function CheckPrinter: Boolean;
Var temp: byte;
The begin
Temp:=GetPrinterStatus;
Result: the not=(((temp and $80)=0)/busy/printer
Or ((temp and $20) & lt;> 0)//printer paper out
Or ((temp and $10)=0)//printer offline
Or ((temp and $8)=0));//printer error;
end;
Runtime prompts ring instruction,
The Windows xp system seems to be able to directly to the I/O operations,
For each master, what else way?
CodePudding user response:
Online, etc., in a hurry