how to disabled network adapter !!!!? how to disabled network adapter !!!!? tarekmomtaz (Programmer) (OP) 1 Aug 17 17:10 hello everyone how i can disabled/enabled NetworkAdapter using vfp code thank's for help RE: how to disabled network adapter !!!!? Koen Piller (Programmer) 1 Aug 17 22:13 Hi, Maybe this article will be of help to you? Jockey2 RE: how to disabled network adapter !!!!? GriffMG (Programmer) 2 Aug 17 08:05 Jockey2, There is no article linked in your reply. Regards Griff Keep ing There are 10 kinds of people in the world, those who understand binary and those who don't. I'm trying to cut down on the use of shrieks (exclamation marks), I'm told they are !good for you. RE: how to disabled network adapter !!!!? Koen Piller (Programmer) 2 Aug 17 12:08 Hi, This article : Link should help you. Regards, Jockey2 RE: how to disabled network adapter !!!!? mgagnon (Programmer) 14 Aug 17 09:25 Depending on the version of windows you have, this may work (This example enables the network connection, just reverse the action) CODE --> foxproPublic Array aconnections aconnections='' LOCAL singleconnection i = 1 o = Createobject("Shell.Application") ns=o.NameSpace (3) For Each oItems In ns.Items If oItems.Name ="Network Connections" && Windows Anglais colNetwork = oItems.getfolder If Vartype(colNetwork) = "O" For Each colConn In colNetwork.Items If Alen(aconnections)= 1 And Empty(aconnections) Else Dimension aconnections[ALEN(aconnections)+1] Endif aconnections[i]=colConn.Name i = i +1 Next Endif Endif Next For i = 1 To Alen(aconnections) If "Titan" $ aconnections[i] &&Un example Connect(aconnections[i]) Endif Next Function Connect(lcConnexion) For Each colConn In colNetwork.Items If colConn.Name = lcConnexion singleconnection = colConn Exit Endif Next For Each clsVerb In singleconnection.Verbs If "C&onnect" = clsVerb.Name Or "En&able" = clsVerb.Name Try singleconnection.InvokeVerb("C&onnect") Catch singleconnection.InvokeVerb("En&able") ENDTRY Endif Next Endfunc Mike Gagnon If you want to get the best response to a question, please check out FAQ184-2483: How to get the best response from the forum first.