问了好久都没人知道???????????

wh_mimi 2003-07-01 09:33:19
我想做个打印机驱动程序自动安装,
用AddPrinterDriver 和 AddPrinter两个函数做,
在手工装驱动后AddPrinter函数工作的很好。
但使用AddPrinterDriver却怎样都不行。
不晓得PDriverInfo3参数怎样写,大家有没有具体的例子。
只要关于AddPrinterDriver的就可以了,如果我搞不定的话可能要失业了。
大伙帮帮忙,分不够可以再加的
...全文
52 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
wh_mimi 2003-07-01
  • 打赏
  • 举报
回复
我也拷贝了,在这个目录下C:\WINNT\system32\spool\drivers\w32x86\3,但还是不行
naughtyboy能请教你吗?我的QQ:150383457
这件事真的很急,我都搞了几天了
naughtyboy 2003-07-01
  • 打赏
  • 举报
回复
AddPrinterDriver调用以前,驱动程序所需要的所有文件必须要拷贝到系统的打印机驱动程序目录下
wh_mimi 2003-07-01
  • 打赏
  • 举报
回复
楼上的,你的方法我都早就试过了,好像不行,不过还是谢谢你了。
我想找个具体点的例子
wsz1995 2003-07-01
  • 打赏
  • 举报
回复
The DRIVER_INFO_3 structure contains printer driver information.

typedef struct _DRIVER_INFO_3 { // dri3
DWORD cVersion;
LPTSTR pName;
LPTSTR pEnvironment;
LPTSTR pDriverPath;
LPTSTR pDataFile;
LPTSTR pConfigFile;
LPTSTR pHelpFile;
LPTSTR pDependentFiles;
LPTSTR pMonitorName;
LPTSTR pDefaultDataType;
} DRIVER_INFO_3;


Members

cVersion

Specifies a printer-driver version number.

pName

Points to a null-terminated string that specifies the name of the driver (for example, "QMS 810").

pEnvironment

Points to a null-terminated string that specifies the environment for which the driver was written (for example, "Windows x86" or "Windows NT R4000").

pDriverPath

Points to a null-terminated string that specifies a filename or full path and filename for the file that contains the device driver (for example, "C:\DRIVERS\PSCRIPT.DLL").

pDataFile

Points to a null-terminated string that specifies a filename or a full path and filename for the file that contains driver data (for example, "C:\DRIVERS\QMS810.PPD").

pConfigFile

Points to a null-terminated string that specifies a filename or a full path and filename for the device driver's configuration dynamic-link library (for example, "C:\DRIVERS\PSCRPTUI.DLL").

pHelpFile

Points to a null-terminated string that specifies a filename or a full path and filename for the device driver's help file.

pDependentFiles

Points to a null-terminated string that specifies the files the driver is dependent on. Each filename in the string is also terminated with a null (for example, "PSCRIPT.DLL\0QMS810.PPD\0PSCRPTUI.DLL\0PSPCRIPTUI.HLP\0PSTEST.TXT\0\0").

pMonitorName

Points to a null-terminated string that specifies a language monitor (for example, "PJL monitor"). This member can be NULL and should be specified only for printers capable of bidirectional communication.

pDefaultDataType

Points to a null-terminated string that specifies the default data type of the print job (for example, "EMF").
naughtyboy 2003-07-01
  • 打赏
  • 举报
回复
呵呵
恭喜楼主了
公司不让上QQ,没办法
sigh
wh_mimi 2003-07-01
  • 打赏
  • 举报
回复
终于搞定了

1,183

社区成员

发帖
与我相关
我的任务
社区描述
Delphi Windows SDK/API
社区管理员
  • Windows SDK/API社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

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