Delay startup items

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Any ideas how I can delay the running of some startup items? As an example,
MSN messenger runs and attempts to log in before my internet connection is
active and therefore returns an error everytime I turn on my PC.

I would have thought that theres a switch I could add after the shortcut
command.

Thanks guys.

Matt
 
Firstly, uncheck the option within MSN that starts it when starting Windows
(Tools > Options > General)

A .vbs script (shortcut in startup folder) like this would delay the startup
by an arbitrary number of milliseconds (in this case 30000 = 30 seconds)

'************************************************
set WshShell = WScript.CreateObject("WScript.Shell")

'Wait 30 seconds
wscript.sleep 30000

'Run MSN
wshshell.Run """C:\Program Files\MSN Messenger\msnmsgr.exe"""
'**************************************************

Alternatively, you could have a startup script (again .vbs) that tested for
an active internet connnection, such as

'**********************************************************
set WshShell = WScript.CreateObject("WScript.Shell")
set ipfinder = createobject("rcbdyctl.setting")

do
wscript.sleep 5000
loop until online = true

'Run MSN
wshshell.Run """C:\Program Files\MSN Messenger\msnmsgr.exe"""

Function online

online = false
ipaddress = ipfinder.GetIPAddress
if len(trim(ipaddress))<>0 then online = true

End Function
'**********************************************************

Jon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top