本文介绍了Vista/Windows 7中未加载端口监视器DLL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经基于"Virtual Image Printer"开源项目编写了端口监视器.即使在基于NSIS的安装过程已完成并且打印机已安装的情况下,它在XP上也能正常工作,但无法在Win7上加载端口监视器DLL.

我怀疑问题是(a)在INF或注册表中,并且打印机,端口和DLL不能以某种方式连接在一起,或者(b)某些东西停止了DLL的加载,但是我不知道是什么.

任何帮助将不胜感激,这真让我发疯!

Rik.
[email protected]


安装后的注册表项

I have written a port monitor based on the "Virtual Image Printer" open-source project. It works fine on XP but fails to load the port monitor DLL on Win7, even though the NSIS-based install process has worked and the printer is installed.

I suspect the problem is either (a) in the INF or the registry and that somehow the printer, port and DLL are not connected together, or (b) something stops the DLL loading, but I don''t know what.

Any help would be very much appreciated, this is driving me nuts!

Rik.
[email protected]


Registry entries after install

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print ->
 \Environments\Windows NT x86\Drivers\Version-3\MyPrinter
 \Monitors\MyPrinter_Port
 \Printers\MyPrinter

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion ->
 \Print\Printers\MyPrinter\DsDriver,DsSpooler,PnPData,PrinterDriverData
 \Ports - has value "MyPrinter_Port"



INF文件:

[版本]
签名="$ Windows NT $"
ClassGUID = {4D36E979-E325-11CE-BFC1-08002BE10318}
类=打印机
Provider ="Ruk"
DriverVer = 08/03/2010,1.1.1.1

[制造商]
%Ruk%" = Ruk,NTx86,NTx86.6.0

[Ruk]
"MyPrinter" = DriverInstall
[Ruk.NTx86]
"MyPrinter" = DriverInstall
[Ruk.NTx86.6.0]
"MyPrinter" = DriverInstall

;参观前及参观后Vista目前与未实现的软件包相同...
[DriverInstall]
CopyFiles = @ MyPrinter.dll,@ MyPrinter.gpd,@ RukUSB.dll
DataFile = MyPrinter.gpd
Include = NTPRINT.INF
DataSection = UNIDRV_DATA
Needs = UNIDRV.OEM,UNIDRV_DATA,TTFSUB.OEM

;安装端口监视器
; (没什么区别)
; [PortMonitors]
;"MyPrinter_Port" = MyPrinter_Port
;
; [MyPrinter_Port]
; CopyFiles = @ MyPrinter.dll,@ MyPrinter.gpd,@ RukUSB.dll
; PortMonitorDll = MyPrinter.dll

[DestinationDirs]
DefaultDestDir = 66000

[SourceDisksNames.x86]
1 =%MediaDescription%,,"I386"

[SourceDisksFiles]
MyPrinter.gpd = 1
MyPrinter.dll = 1
RukUSB.dll = 1

[字串]
MediaDescription ="Ruk打印机驱动程序磁盘"
Ruk =我的打印机"



INF file:

[Version]
Signature="$Windows NT$"
ClassGUID={4D36E979-E325-11CE-BFC1-08002BE10318}
Class=Printer
Provider="Ruk"
DriverVer=08/03/2010, 1.1.1.1

[Manufacturer]
"%Ruk%"=Ruk, NTx86, NTx86.6.0

[Ruk]
"MyPrinter" = DriverInstall
[Ruk.NTx86]
"MyPrinter" = DriverInstall
[Ruk.NTx86.6.0]
"MyPrinter" = DriverInstall

; Pre-vista & post-Vista currently the same as packages not implemented...
[DriverInstall]
[email protected],@MyPrinter.gpd,@RukUSB.dll
DataFile=MyPrinter.gpd
Include=NTPRINT.INF
DataSection=UNIDRV_DATA
Needs=UNIDRV.OEM,UNIDRV_DATA,TTFSUB.OEM

; Install port monitor
; (Didn''t make any difference)
;[PortMonitors]
;"MyPrinter_Port" = MyPrinter_Port
;
;[MyPrinter_Port]
;[email protected],@MyPrinter.gpd,@RukUSB.dll
;PortMonitorDll = MyPrinter.dll

[DestinationDirs]
DefaultDestDir=66000

[SourceDisksNames.x86]
1 = %MediaDescription%,,,"I386"

[SourceDisksFiles]
MyPrinter.gpd= 1
MyPrinter.dll= 1
RukUSB.dll= 1

[Strings]
MediaDescription = "Ruk Printer driver disk"
Ruk = "My Printers"

推荐答案




这篇关于Vista/Windows 7中未加载端口监视器DLL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-29 01:21