Click here to Skip to main content
15,892,517 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Excel, Pick from Drop down list and VB Pin
RichardGrimmer3-Feb-04 2:04
RichardGrimmer3-Feb-04 2:04 
GeneralExcel, Pick from Drop down list and VB Pin
RichardGrimmer1-Feb-04 23:28
RichardGrimmer1-Feb-04 23:28 
QuestionCan any one help me to include MDAC in my project MSI file Pin
Het21091-Feb-04 23:06
Het21091-Feb-04 23:06 
AnswerRe: Can any one help me to include MDAC in my project MSI file Pin
jimpar2-Feb-04 5:41
jimpar2-Feb-04 5:41 
QuestionHow to disable the NIC? Pin
younghand1-Feb-04 21:30
younghand1-Feb-04 21:30 
AnswerRe: How to disable the NIC? Pin
Dave Kreskowiak2-Feb-04 4:41
mveDave Kreskowiak2-Feb-04 4:41 
GeneralRe: How to disable the NIC? Pin
vbTom22-Mar-04 4:35
vbTom22-Mar-04 4:35 
GeneralRe: How to disable the NIC? Pin
Dave Kreskowiak22-Mar-04 7:59
mveDave Kreskowiak22-Mar-04 7:59 
Unfortunately, the WMI functionality that is exposed doesn't work. The idea is to get the ServiceName from the NetworkAdapter object. Then use the StopService method of the ServiceName object to stop the driver. But, alas, the driver won't stop or pause.

Apparently it can't be done through WMI. But it could be done thru calls to the PnP Device Manager. You would have to call IoGetDeviceInterfaces with the class GUID of the network adapter class to get a linked list of SymbolicLinks. Once you find the Symbolic Link name, you can pass that to IoSetDeviceInterfaceState with the Enabled param set to False.

I haven't tried to do this, and frankly, don't have to the time to write any code for it. But after about an hour of research, this is the only method I can come up with to disable/enable a NIC through code. I THINK it's the same method used by the Device Manager when you disable/enable a device through there.


RageInTheMachine9532
GeneralRe: How to disable the NIC? Pin
vbTom22-Mar-04 8:07
vbTom22-Mar-04 8:07 
GeneralRe: How to disable the NIC? Pin
Dave Kreskowiak22-Mar-04 8:18
mveDave Kreskowiak22-Mar-04 8:18 
GeneralRe: How to disable the NIC? Pin
vbTom22-Mar-04 11:52
vbTom22-Mar-04 11:52 
GeneralRe: How to disable the NIC? Pin
Dave Kreskowiak22-Mar-04 12:41
mveDave Kreskowiak22-Mar-04 12:41 
GeneralNetwork Communication Pin
ineedhelp1-Feb-04 21:25
ineedhelp1-Feb-04 21:25 
GeneralRe: Network Communication Pin
Matthew Hazlett2-Feb-04 10:09
Matthew Hazlett2-Feb-04 10:09 
GeneralRe: Network Communication Pin
John Kuhn3-Feb-04 13:31
John Kuhn3-Feb-04 13:31 
GeneralRe: Network Communication Pin
John Kuhn4-Feb-04 19:32
John Kuhn4-Feb-04 19:32 
Generaldataadapter and dataset with multiple tables Pin
rdk7171-Feb-04 16:15
rdk7171-Feb-04 16:15 
GeneralHTTP URL get Pin
pmasknguyen1-Feb-04 6:31
pmasknguyen1-Feb-04 6:31 
GeneralRe: HTTP URL get Pin
Tom Larsen2-Feb-04 9:42
Tom Larsen2-Feb-04 9:42 
GeneralBasic differences Pin
bensoncd1-Feb-04 6:30
bensoncd1-Feb-04 6:30 
GeneralRe: Basic differences Pin
Hesham Amin1-Feb-04 10:04
Hesham Amin1-Feb-04 10:04 
GeneralRe: Basic differences Pin
Dan Morris2-Feb-04 2:38
Dan Morris2-Feb-04 2:38 
GeneralRe: Basic differences Pin
Edbert P2-Feb-04 19:35
Edbert P2-Feb-04 19:35 
GeneralRe: Basic differences Pin
RichardGrimmer3-Feb-04 2:18
RichardGrimmer3-Feb-04 2:18 
GeneralRe: Basic differences Pin
Steve S9-Feb-04 7:22
Steve S9-Feb-04 7:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.