阅读:963回复:3
Win98下的打印驱动的安装?
已经搞了好几天了,还是不行,用addprinterdriver,addprinter有没有成功的同志啊?帮帮我吧。呵呵。
|
|
沙发#
发布于:2004-07-02 08:59
DRIVER_INFO_2 di2;
ZeroMemory(&di2, sizeof(DRIVER_INFO_2)); di2.cVersion = 0x0; di2.pName = "Virtual Printer"; di2.pEnvironment = "Windows NT x86"; di2.pDriverPath = "c:\\windows\\cbitmap.drv"; di2.pDataFile = "c:\\windows\\cbitmap.drv"; di2.pConfigFile = "c:\\windows\\cbitmap.drv"; bool b=AddPrinterDriver(NULL, 2, (LPBYTE)&di2); HANDLE hPrinter; PRINTER_INFO_2 pi2; ZeroMemory(&pi2, sizeof(PRINTER_INFO_2)); pi2.pPrinterName = "Virtual Printer"; pi2.pPortName = "FILE1:"; pi2.pDriverName = "Virtual Printer"; pi2.pPrintProcessor = "WinPrint"; pi2.pDatatype = "RAW"; hPrinter = AddPrinter(NULL, 2, (LPBYTE)&pi2); 以上是我的代码, |
|
板凳#
发布于:2004-07-02 17:37
di2.pDriverPath = "c:\windows\cbitmap.drv"; di2.pDataFile = "c:\windows\cbitmap.drv"; di2.pConfigFile = "c:\windows\cbitmap.drv"; 必须是系统目录,文件当然也要考到系统目录 |
|
|
地板#
发布于:2004-07-02 23:17
谢谢snow的回答啦,我已经解决此问题,不过并非你所说的,因为我已经做好了COpy 工作。呵呵。
|
|