How do I connect to internet from command prompt?
I'm trying to create a task that connects to internet at a specified time. I have a broadband wired connection that I use to connect to the internet. How do I manage connect/disconnect of this connection from command prompt?
Update/Additional Info:
Here's the actual situation:
My ISP offers free download from 2:00AM to 7:00AM. Thus I schedule my downloads during that period. I've been doing this without any problems until recently, when by looking at the logs I noticed I'm being disconnect sometime before 2:00AM. I have checked the auto reconnect on my connection for such cases but (again by checking the logs) I'm not able to reconnect automatically. So I'm guessing during that period of time (maybe for a few minutes) I cannot reconnect. So I want to check my connection at around 2:10AM and if it's disconnected, I want to reconnect it. Which brings us the the question of:
How do I schedule a windows task to connect to a broadband connection?
P.S. I know reconnection is possible. I tried it once, sometime around 3:00AM and it worked.
Update2: This is how I connect
Note: Do not be mistaken, this is NOT a wireless connection.
Solution 1:
rasdial "connection name"
or in your case:
rasdial "Bita"
Solution 2:
Copy the text below into a text file and save it as a *.bat file Change connect name if needed.......
@ECHO OFF
ping 8.8.8.8 | find "unreachable"
if errorlevel 1 goto :eof
netsh wlan connect name="Bita"
pause
@magicandre1981 has part of the answer,maybe a mod can merge my answer into his....