Cool-LV Posted November 9, 2007 Report Share Posted November 9, 2007 Hello All, I wanna disconnet/connect the network with LV, call with API or .net to realize ? Please help to give a tip or thread, thanks in advance. Quote Link to comment
Mellroth Posted November 9, 2007 Report Share Posted November 9, 2007 QUOTE(Cool-LV @ Nov 8 2007, 04:55 AM) Hello All, I wanna disconnet/connect the network with LV, call with API or .net to realize ? Please help to give a tip or thread, thanks in advance. Can you be more specific about your problem? Do you want to disable the network interface on the computer, or do you want to change computer IP settings, or do you want to break a TCP connection, or ... /J Quote Link to comment
Tom Limerkens Posted November 9, 2007 Report Share Posted November 9, 2007 Assuming you work in Windows, and you want to map/unmap network drives dynamically. It can be done quit easily through the command prompt using the 'net use' commands. type 'net use /?' here some examples : <BR>example to connect :net use T \\companyserver\measurementdatashare mypassword /USER:mydomain\myaccountexample to disconnect drivemap above : net use T \DELETE Success, Tom Quote Link to comment
Cool-LV Posted November 16, 2007 Author Report Share Posted November 16, 2007 thanks all, and Sorry for the not clear question, OS is WinXP, the function that simulate open the local connection status, and press disable network, and press enable to enable the network, thanks upwards guy's suggestion that I haven't tried, because I see it needs user password to connect, should any tip be easier ? Quote Link to comment
Rolf Kalbermatter Posted November 20, 2007 Report Share Posted November 20, 2007 QUOTE(Cool-LV @ Nov 14 2007, 09:13 PM) thanks all,and Sorry for the not clear question, OS is WinXP, the function that simulate open the local connection status, and press disable network, and press enable to enable the network, thanks upwards guy's suggestion that I haven't tried, because I see it needs user password to connect, should any tip be easier ? Well, it's not getting much clearer, but if the password is the only problem you are having, that is only required for remote shares that have a password defined. If it is a share that is open for anyone to read, you wouldn't need the password to connect to it. For a share that is password protected, their is no way to connect to it without password. Rolf Kalbermatter Quote Link to comment
Justin Goeres Posted November 20, 2007 Report Share Posted November 20, 2007 QUOTE(Cool-LV @ Nov 14 2007, 07:13 PM) and Sorry for the not clear question, OS is WinXP, the function that simulate open the local connection status, and press disable network, and press enable to enable the network, thanksupwards guy's suggestion that I haven't tried, because I see it needs user password to connect, should any tip be easier ? Like rolfk said, it's still really hard to understand what you're trying to do. If you want to map/unmap network drives (with or without password) the other suggestion above is a good one. If you're trying to access information about network adapters in the system, you can do that with the ipconfig command: C:\>ipconfig /?USAGE: ipconfig [/? | /all | /renew [adapter] | /release [adapter] | /flushdns | /displaydns | /registerdns | /showclassid adapter | /setclassid adapter [classid] ]...etc... Quote Link to comment
Cool-LV Posted November 21, 2007 Author Report Share Posted November 21, 2007 OK, attached a Picture to tell details, the function is as the sam as press the disable button to diable connection, and press enable to reconnect it. thanks @! Quote Link to comment
Rolf Kalbermatter Posted November 21, 2007 Report Share Posted November 21, 2007 QUOTE(Cool-LV @ Nov 20 2007, 01:47 AM) OK, attached a Picture to tell details, the function is as the sam as press the disable button to diable connection, and press enable to reconnect it. thanks @! The post before your post explains that exactly. ipconfig can do that too. ipconfig /release [adapter name] will basically disable the network interface. ipconfig /renew [adapter name] will reconnect it. Of course there is certainly a way to do this accessing the Windows API, but the network enumeration API uses data structures that you most probably do not want to deal with in the Call Library Node, believe me. Rolf Kalbermatter Quote Link to comment
Cool-LV Posted November 22, 2007 Author Report Share Posted November 22, 2007 QUOTE(rolfk @ Nov 20 2007, 09:15 AM) The post before your post explains that exactly. ipconfig can do that too. ipconfig /release [adapter name] will basically disable the network interface. ipconfig /renew [adapter name] will reconnect it.Of course there is certainly a way to do this accessing the Windows API, but the network enumeration API uses data structures that you most probably do not want to deal with in the Call Library Node, believe me. Rolf Kalbermatter Well, thanks all and Rolfk Quote Link to comment
Cool-LV Posted November 22, 2007 Author Report Share Posted November 22, 2007 QUOTE(rolfk @ Nov 20 2007, 09:15 AM) The post before your post explains that exactly. ipconfig can do that too. ipconfig /release [adapter name] will basically disable the network interface. ipconfig /renew [adapter name] will reconnect it.Of course there is certainly a way to do this accessing the Windows API, but the network enumeration API uses data structures that you most probably do not want to deal with in the Call Library Node, believe me. Rolf Kalbermatter Well, thanks all and Rolfk Quote Link to comment
Mellroth Posted November 22, 2007 Report Share Posted November 22, 2007 QUOTE(rolfk @ Nov 20 2007, 10:15 AM) The post before your post explains that exactly. ipconfig can do that too. ipconfig /release [adapter name] will basically disable the network interface. ipconfig /renew [adapter name] will reconnect it. Cool-LV, just note that Rolf's suggestion of using the ipconfig /release and /renew, is not working if your network cars are configured using static IP addresses, i.e. they must be configured to use DHCP. Good luck! /J Quote Link to comment
Mellroth Posted November 22, 2007 Report Share Posted November 22, 2007 QUOTE(rolfk @ Nov 20 2007, 10:15 AM) The post before your post explains that exactly. ipconfig can do that too. ipconfig /release [adapter name] will basically disable the network interface. ipconfig /renew [adapter name] will reconnect it. Cool-LV, just note that Rolf's suggestion of using the ipconfig /release and /renew, is not working if your network cars are configured using static IP addresses, i.e. they must be configured to use DHCP. Good luck! /J Quote Link to comment
Cool-LV Posted November 28, 2007 Author Report Share Posted November 28, 2007 I use DEVCON to realize. thanks all. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.