Link to home
Start Free TrialLog in
Avatar of ksander
ksander

asked on

Can you automatically open IE if it's not open already?

We have a library with PCs for patrons use. The IE home page, with links to the collection as well as the Internet, is where we want users to start. We've asked people to hit the Home icon when they leave so the PC will be ready for the next patron.  Some do, some don't, and some shut down IE.

Primarily what we're looking for is a process that will periodically check to see if IE is open and, if it isn't, open it.

Of secondary interest is a way to have IE automatically go to the home page if there has been no activity for x amount of time.  

Can these be done ?
Avatar of infex
infex

Yes.

Any program which is in the "startup group" opens automatically on startup of the machine.

You can also use the sheduller to start a program at a given time.

Hope this helps
Avatar of ksander

ASKER

I know anything that will do what I need will have to either be in the 'start group' or be called by Scheduler, but I don't know what that would be.

I can't just schedule IE to start every 15 minutes. I need something that will check every 15 minutes to see if IE is open and, if it isn't, open it.

My local library just has a signed taped to the PC's that say something to the effect:

To begin, click on Start...Internet Explorer

 (and they've disabled just about everything else).
Avatar of ksander

ASKER

We've tried that and would like something else.
I use a batch file and Pstools to do something similar on one of my systems.  Basically, Pstools is a collection of utilities (google pstools).  The one I use is pskill.  There is a help file with examples for syntax and such.

For your example, it would be something like this:
ResetIE.bat
  pskill iexplore.exe
  "c:\program files\internet explorer\iexplore.exe"

Line 1 will kill ALL instances of iexplore that are running.
Line 2 will restart IE.  If you have your web page as the home page, then it will open that up when IE starts.

As for when to run this, I'm not sure.  You don't want it to run every 10 minutes because it will kill IE every 10 minutes.  If users have to login then it could be placed in All Users\Startup.  

Let me see if I can find something that monitors idle time and can run something based on idle time.
Oops..  it looks like you can schedule this in Scheduled Tasks.  Under settings, there is a section called idle time.  You can set this to your liking and have it call the batch file in my previous comment.
cciesliga
The problem with your first solution "ResetIE.bat" is that this will be called one time,and then the command would close, but what would call it again?
you can't use idle time - if someone is sitting at the computer, reading an online manuscript then the idle time could interfer with their workings. Also if the user turns to visit to the person next to them, gets up to use the restroom, the list could go on and on why idle time may not be the best solution used with that particular batch file because it closes any open IE window.

The batch file should first check to see if the window is open, if so then close the batch file
else continue with your steps of restarting IE - I don't think I'd kill IE at all.
I don't think there will be a fool proof way of do what this poster wants. To many variables, if the current user is on a page doing research, thus writing on paper, and the time times out, causing the page to refresh to the homepage, then the user would lose his current page, and perhaps his temper.

Using the idle process may not work as well. What are you going to do? Someone stands up and returns their computer check out tag, and immediately someone else sits down, where's the homepage? How will the computer know there is a new person at the computer? The computer is not idle so it won't call the batch file to set IE back to the home page.

I think I would set up vnc on the computers, monitor them from afar and click the home button or open IE from the VPN application. There's just too many possible variables that could effect an automated process, in this case.

If you're interested in VNC, it's free and you'll be able to locate it by googling - VNC download

Avatar of ksander

ASKER

We don't want to kill IE, we want to start it if it isn't running.
And we don't have a person who can monitor our PCs from afar.
I don't know if there is any "ready-made" util to do what you want.
What you need is a program that continuously checks if IE is beinf executed, and if it isn't, then start it up again.

Ideally it should have two tasks running, to prevent users from killing this startIE program too.
So, it would check if both IE and the StartIE program was running.

Maybe someone here can quickly code a script for that.
You could probably make a vbscript to do that and I can post one here later on if you want to go that way and just basically get your task scheduler to run the vbscript every 15 mins :)
Avatar of ksander

ASKER

If a vbscript can unobtrusively check to see if IE is running and if not start it - that's just what I need.
ASKER CERTIFIED SOLUTION
Avatar of cciesliga
cciesliga

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ermm..  just call the vbs file in the scheduler, don't use cscript.
are you sure about not using cscript on the scheduler?
for my vbs's I had the need to call it "cscript whatver.vbs"
it may depend on which OS version you're running.  with XP, in my scheduled tasks, I'm just calling the vbs file.  of course, if it doesn't work with just the "filename.vbs", then use "cscript filename.vbs"
I'm on XP SP2 fully updated... but such behaviours are not that strange, coming from MS... :)
Avatar of ksander

ASKER

I'm not familiar with scripts.
There are 2 scripts, CheckIE and RunInvis, and 1 batch file, right?
Any other components?
What are the lines in the batch file?
These are XP SP2 machines. Does the standard configuration have everything need to run this?
2 scripts and 1 batch

filename
********
file contents
********

so, CheckIE.bat has this in it: cscript CheckIE.vbs

Once you have all 3 files created, then setup a schedule to run every 15 minutes, or whatever, and have it run RunInvis.vbs

Let me know if it's still not clear.
sorry I didnt get a chance to post back a vbscript , I was at work when I made that post and I didnt get a chance to get online :) However there are already vbscripts above which will do what you want :)

My appologies !

Kind regards

Gecko
Avatar of ksander

ASKER

It works perfectly!  (manually, that is)


I haven't been able to get it to run with Scheduler, but that doesn't matter because it doesn't look like Scheduler can be set to run the process every n minutes.

Does anybody know of another scheduler that might do it ?
Scheduled tasks can do it.  Under the schedule tab, click on the advanced button.  In the Advanced Options window, you can select a repeat frequency.  The task I have scheduled runs every 5 minutes for a duration of 24 hours.  I have it set to run daily at 12:00am every 1 day under the normal schedule tab.
Avatar of ksander

ASKER

You're right - Scheduled tasks is doing it.


Thanks very much.
You're welcome.  Let me know if there's anything else.