-
August 6th, 2009, 11:12 AM
#1
Network Adapter API
So I am installing a driver for a USB network adapter. Is there a similar set of API's to uninstall a network adapter like printers. For example DeletePrinterDriverEx, is there a DeleteNetworkDriverEx somewhere? I haven't had luck finding anything.
-
August 6th, 2009, 11:58 AM
#2
Re: Network Adapter API
How about using a console?
Try to execute:
Code:
net use [drive] /delete /yes
via WinExec()
Source:
http://support.microsoft.com/kb/308582
-
August 6th, 2009, 01:07 PM
#3
Re: Network Adapter API
It's not a network drive. It is a device that uses a network adapter to act like a network device. Almost like installing a printer as a network printer but it connects via USB for example. When it is installed it shows up in the Device Manager as a Network Adapter.
-
August 6th, 2009, 02:51 PM
#4
Re: Network Adapter API
So I did an EnumServiceStatus and found the driver service. But just doind a DeleteService wont uninstall the driver will it? Thanks for all the help...
Last edited by rjbez; August 6th, 2009 at 03:40 PM.
Reason: different question.
-
August 6th, 2009, 03:52 PM
#5
-
August 6th, 2009, 04:22 PM
#6
Re: Network Adapter API
I need something that will be packaged into an application that is going to uninstall the entire driver. DevCon says it is to only be used for debugging purposes...I'm looking for something that is standard in the WDK/SDK (VS). If you do:
OpenSCManager
EnumServiceStats (SERVICE_DRIVER)
OpenService
QueryServiceStatus(service, &status);
ControlService(service, SERVICE_CONTROL_STOP, &status);
DeleteService(service);
will it 'uninstall' the driver service or just delete it from the services list? Is this a safe way to does this?
-
August 6th, 2009, 04:34 PM
#7
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|