Registry Tip #309: Remove Printer Definition from the Registry |
Hits: Failed to execute CGI : Win32 Error Code = 3
|
|
There is a problem with NT printer definitions that may cause you problems. You follow standard advice to uninstall and reinstall the printer driver. Sometimes this doesn't fix the problem and you have no choice but to remove a printer. When you use the Remove or Delete Printer options in Print Manager, the printer connection disappears immediately. However, the spooler simply marks the printer for deletion. NT doesn't actually delete the printer until you reboot the system. Sometimes NT will delete the definition if you stop and restart the spooler. Sometimes it doesn't. If this doesn't work, and you will find out when you try to redefine the printer. No issue for workstations. You can reboot. Unfortunately there are servers which can not be rebooted (or at least not for something like a printer definition). For servers which can not be rebooted, you can remove the printer definition from the registry by hand prior to the reinstall.
If it is a local printer (My Computer), go to the following registry keys and delete the respective entries:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Environments\ Windows NT x86\ Drivers\Version-2\
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers\
If it is a network printer (network printer server or \\), go to the following registry keys and
delete the respective <Server Name> and <Printer Name> entries:
<P>
HKEY_CURRENT_USER\Printers\Connections\<Server Name>
<P>
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Providers\
LanMan Print Services\Servers\<Server Name>\Printers\<Printer Name>
<P>
After the registry edit, you need to stop and
restart the spooler service. At this point, you'll be able to reinstall the printer driver
correctly.
<P>
<a href="http://www.amazon.com/exec/obidos/ASIN/1562059416/ntregistrandtips" Target="_blank">
A Settings Reference</a>
<BR>
<a href="http://www.amazon.com/exec/obidos/ASIN/1562059416/ntregistrandtips" Target="_blank">
<img src="/amazon/regsettingref.gif"></a>
<table><tr>
<td><a href="http://www.amazon.com/exec/obidos/ASIN/1562059416/ntregistrandtips/" Target="_blank"><img src="/amazon/amazon.jpg"> </a>
<td><a href="http://www.amazon.co.uk/exec/obidos/ASIN/1562059416/waynswindntw2kre/" Target="_blank"><img src="/amazon/amazonuk.gif"> </a>
<td><A HREF="http://bn.bfast.com/booklink/click?sourceid=27201174&ISBN=1562059416" Target="_blank"> <img src="/amazon/bn.jpg"></A>
</tr></table>
<!---
A Settings Reference
--->
<P>
<a href="http://www.amazon.com/exec/obidos/ASIN/0079136559/ntregistrandtips" Target="_blank">
A Professional Reference</a>
<BR>
<a href="http://www.amazon.com/exec/obidos/ASIN/0079136559/ntregistrandtips" Target="_blank">
<img src="/amazon/regprofref.gif"></a>
<table><tr>
<td><a href="http://www.amazon.com/exec/obidos/ASIN/0079136559/ntregistrandtips/" Target="_blank"><img src="/amazon/amazon.jpg"> </a>
<td><a href="http://www.amazon.co.uk/exec/obidos/ASIN/0079136559/waynswindntw2kre/" Target="_blank"><img src="/amazon/amazonuk.gif"> </a>
<td><A HREF="http://bn.bfast.com/booklink/click?sourceid=27201174&ISBN=0079136559" Target="_blank"> <img src="/amazon/bn.jpg"></A>
</tr></table>
<!---
A Professional Reference
--->
<P><font size=-1>
<P></font>
<h3>
<FORM>
<INPUT
TYPE = "BUTTON"
VALUE ="Home"
onClick ="window.location = '../index.shtml';">
<INPUT
TYPE = "BUTTON"
VALUE ="Previous Registry Tip"
onClick ="window.location = 'rtips308.shtml';">
<INPUT
TYPE = "BUTTON"
VALUE ="Next Registry Tip"
onClick ="window.location = 'rtips310.shtml';">
<INPUT
TYPE = "BUTTON"
VALUE ="Registry Tip Index"
onClick ="window.location = 'index.shtml';">
</FORM>
<hr>
</BODY>
</HTML>