Pages: [1]   Go Down
Author Topic: Sample VBScript to run IE and auto logon to pandora for external display  (Read 933 times)
0 Members and 1 Guest are viewing this topic.
FMSer
Newbie
*

Karma: 0
Offline Offline

Posts: 7


View Profile
« on: November 17, 2010, 06:14:37 PM »

We have a TV monitor connected to a PC that will display the group view of our monitored systems.  I wrote the following VB script to run the autologin URL (see http://openideas.info/smf/index.php/topic,1775.0.html on how to get autologin to work)

The computer is configured to autologon to Windows, then launch the VB script that opens the URL in full-screen mode with no scrollbars.

'******************************************************************
'  Set the URL that will open in the IE Window
'******************************************************************
StrURL = "http://pandoraserver.domain.com/pandora_console/index.php?loginhash=auto&loginhash_user=autologin&loginhash=a3e69bcc9b27b0678c21198d0c08597f&sec=estado&sec2=operation/agentes/group_view&refr=30"

Set wshShell = WScript.CreateObject ("WSCript.shell")
Set objExplorer = CreateObject("InternetExplorer.Application")

objExplorer.visible = 0
'******************************************************************
'Set IE parameters
'******************************************************************
objExplorer.Toolbar = 1
objExplorer.StatusBar = 1
objExplorer.FullScreen = True

objExplorer.navigate(strURL)

'******************************************************************
'Wait for IE to finish loading the URL
'******************************************************************
Do While objExplorer.Busy
   WScript.Sleep 2000   'Sleep added to reduce CPU spike issues
Loop

'******************************************************************
'Show IE Window Now
'******************************************************************
objExplorer.visible = 1


Just put this script in the STARTUP folder for the autologon user.  Hopefully, someone will find this useful.
Logged

miguel
Global Moderator
Sr. Member
*****

Karma: 0
Offline Offline

Posts: 102



View Profile
« Reply #1 on: November 23, 2010, 02:49:41 PM »

Thanks it is useful script for windows user.

Bye.
Logged

Pages: [1]   Go Up
Print
 
Jump to:  


SourceForge.net Logo  This site is monitored by Pandora FMS   ArticaST