Unoffical empeg BBS

Quick Links: Empeg FAQ | RioCar.Org | Hijack | BigDisk Builder | jEmplode | emphatic
Repairs: Repairs

Topic Options
#265263 - 16/09/2005 00:02 Automatically dial a network connection without logging on to Windows
Shonky
pooh-bah

Registered: 12/01/2002
Posts: 2009
Loc: Brisbane, Australia
I have an XP Pro machine that I want to automatically connect to our company VPN from an offsite location.

It will be connected to a remote LAN behind a firewall so internet access will already be there. I just want it to automatically connect to the VPN so it's visible on the company LAN.

So I think I want something to run as a service and start the VPN connection.

Currently, my only solution is a use TweakUI to automatically log on and then have a shortcut to the VPN connection in the Startup folder. The VPN connection is set to automatically connect and not ask for a username and password.

Any ideas guys? Things like Firedaemon only seem to run programs. I can't work out how to start/stop network connections via command line or any other program.

Thanks
_________________________
Christian
#40104192 120Gb (no longer in my E36 M3, won't fit the E46 M3)

Top
#265264 - 16/09/2005 00:09 Re: Automatically dial a network connection without logging on to Wind [Re: Shonky]
robricc
carpal tunnel

Registered: 30/10/2000
Posts: 4931
Loc: New Jersey, USA
Could you make a batch file that says "start link_to_shortcut.lnk" and have Firedaemon run the batch file?
_________________________
-Rob Riccardelli
80GB 16MB MK2 090000736

Top
#265265 - 16/09/2005 00:16 Re: Automatically dial a network connection without logging on to Wind [Re: robricc]
Shonky
pooh-bah

Registered: 12/01/2002
Posts: 2009
Loc: Brisbane, Australia
Quote:
Could you make a batch file that says "start link_to_shortcut.lnk" and have Firedaemon run the batch file?

I thought that would work for sure (kicked myself for forgetting about 'start' since I have used it a bit). I created a shortcut to the VPN connection. Then to test I just ran "start VPN.lnk" from a command shell. It just opened a new command shell . Double clicking VPN.lnk correctly starts the connection though.

Thanks for the idea though.
_________________________
Christian
#40104192 120Gb (no longer in my E36 M3, won't fit the E46 M3)

Top
#265266 - 16/09/2005 00:16 Re: Automatically dial a network connection without logging on to Wind [Re: robricc]
robricc
carpal tunnel

Registered: 30/10/2000
Posts: 4931
Loc: New Jersey, USA
Code:
cmd /k "link to shortcut.lnk"

also seems it may work in a batch file.
_________________________
-Rob Riccardelli
80GB 16MB MK2 090000736

Top
#265267 - 16/09/2005 00:17 Re: Automatically dial a network connection without logging on to Wind [Re: Shonky]
Shonky
pooh-bah

Registered: 12/01/2002
Posts: 2009
Loc: Brisbane, Australia
It would appear that "start xxxx.lnk" is the same as "start" i.e. start doesn't support .lnk shortcuts.
_________________________
Christian
#40104192 120Gb (no longer in my E36 M3, won't fit the E46 M3)

Top
#265268 - 16/09/2005 00:20 Re: Automatically dial a network connection without logging on to Wind [Re: robricc]
Shonky
pooh-bah

Registered: 12/01/2002
Posts: 2009
Loc: Brisbane, Australia
No dice there either
_________________________
Christian
#40104192 120Gb (no longer in my E36 M3, won't fit the E46 M3)

Top
#265269 - 16/09/2005 00:22 Re: Automatically dial a network connection without logging on to Wind [Re: Shonky]
robricc
carpal tunnel

Registered: 30/10/2000
Posts: 4931
Loc: New Jersey, USA
hmm, the cmd /k thing seems to work for me (from the command line at least). I recall 'start' being able to execute shortcuts in the past. Has this changed in XP (not working for me in XP either). Well, that's all I got...
_________________________
-Rob Riccardelli
80GB 16MB MK2 090000736

Top
#265270 - 16/09/2005 00:26 Re: Automatically dial a network connection without logging on to Wind [Re: robricc]
Shonky
pooh-bah

Registered: 12/01/2002
Posts: 2009
Loc: Brisbane, Australia
Quote:
hmm, the cmd /k thing seems to work for me (from the command line at least). I recall 'start' being able to execute shortcuts in the past. Has this changed in XP (not working for me in XP either). Well, that's all I got...


Yeah cmd /k works on an .exe shortcut, but not on a network connection shortcut. "start" is not working on any .lnk files as you are also seeing.

Thanks for your time Rob. Hopefully someone else will pop in with an idea.
_________________________
Christian
#40104192 120Gb (no longer in my E36 M3, won't fit the E46 M3)

Top
#265271 - 16/09/2005 00:38 Re: Automatically dial a network connection without logging on to Wind [Re: Shonky]
robricc
carpal tunnel

Registered: 30/10/2000
Posts: 4931
Loc: New Jersey, USA
Can rasdial dial a VPN?

Sorry, I don't have a VPN to dial into, so I'm just pulling at strings.
_________________________
-Rob Riccardelli
80GB 16MB MK2 090000736

Top
#265272 - 16/09/2005 01:03 Re: Automatically dial a network connection without logging on to Windows [Re: Shonky]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31600
Loc: Seattle, WA
I'll bet it can be done with a rundll call..

Edit: Yeah, what Rob said.
_________________________
Tony Fabris

Top
#265273 - 16/09/2005 02:48 Re: Automatically dial a network connection without logging on to Wind [Re: robricc]
Shonky
pooh-bah

Registered: 12/01/2002
Posts: 2009
Loc: Brisbane, Australia
Quote:
Can rasdial dial a VPN?


It would appear so Thanks Rob. It's connecting to the VPN fine from the command line (although I still need to supply a username and password which I don't think I should). I just need to get that to run as a service and I'm set.

Thanks for the help. My googling did't even come close to those articles I don't think. My search-fu wasn't working well today. I didn't even think to use "RAS" anywhere.
_________________________
Christian
#40104192 120Gb (no longer in my E36 M3, won't fit the E46 M3)

Top