Dynamically Change the Content of a Secondary Monitor

This script example will show you how you can change the content of a secondary monitor by actions on the primary monitor. Please note that we recommend using our Kiosk CMS SiteCaster to achieve this, here is described how to do it.

In this post we will use the SiteKiosk Object Model and the SiteKiosk Player on the secondary monitor instead of SiteCaster to change the monitor content. We will also make use of HTML, Javascript/JScript/WScript. The mehtod will require quite some scripting which is not necessary when using the SiteCaster approach.

We need three files, two HTML files and one Javascript file. 

The first HTML file is for the primary monitor.

	<script type="text/javascript">
		//method to initialize the SK Chrome Object Model
		(new Function(_siteKiosk.getSiteKioskObjectModelCode()))();
		<input id="id_togglesecondarymonitor" type="button" value="Toggle text on secondary monitor" />
	 <script type="text/javascript">
        siteKiosk.ready(function (){
            document.getElementById("id_togglesecondarymonitor").onclick = function () {
                _siteKiosk.objectModel.callHostFunction("system.windows.skLegacy.executeScript", "SiteKiosk.ScriptDispatch.toggleTextOnSecondMonitor();");

It includes HTML code for a button that will toggle the content on the secondary monitor. It also uses the SiteKiosk Object Model each time the button is pressed to call the function toggleTextOnSecondMonitor in the external Javascript file we will have a closer look at below. This specific HTML page is for use in the Chrome browser engine of SiteKiosk (for an IE example please have a look here). It combines the classic SiteKiosk Object Model and the Object Model for Chrome as described here. The ScriptDispatch object can be used to access any member of the external script defined in the SiteKiosk configuration.

The Javascript file that will be added to the SiteKiosk configuration as an external script is next.

//Initialize WScript Shell
var WshShell = new ActiveXObject("WScript.Shell");

//Initialize default registry value on every start of SiteKiosk

//Get the OS type
var OsType = WshShell.RegRead("HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Environment\\PROCESSOR_ARCHITECTURE");

function regWriteValue(valuetowrite){
	if (OsType === "x86"){
		//32bit systems
		WshShell.RegWrite("HKEY_CURRENT_USER\\SOFTWARE\\PROVISIO\\SiteKiosk\\ToggleTextOnSecondaryMonitor", valuetowrite, "REG_DWORD");
		//64bit systems
		WshShell.RegWrite("HKEY_CURRENT_USER\\SOFTWARE\\Wow6432Node\\PROVISIO\\SiteKiosk\\ToggleTextOnSecondaryMonitor", valuetowrite, "REG_DWORD");

function regReadValue(){
	if (OsType === "x86"){
		//32bit systems
		return WshShell.RegRead("HKEY_CURRENT_USER\\SOFTWARE\\PROVISIO\\SiteKiosk\\ToggleTextOnSecondaryMonitor");
		//64bit systems
		return WshShell.RegRead("HKEY_CURRENT_USER\\SOFTWARE\\Wow6432Node\\PROVISIO\\SiteKiosk\\ToggleTextOnSecondaryMonitor");

function toggleTextOnSecondMonitor(){

The external script file can include any sort of Javascript/JScript/WScript and of course the SiteKiosk Object Model. For our example script we will make heavy use of WScript as we are using the WScript shell to access the Windows registry to save the status flag for the content of the secondary monitor. Note that using the registry is only one possible option to communicate between the primary and the secondary monitor, you could for example also write to a file or use a web server instead. The above WScript code reads and writes from/to the Windows registry. Please see the WScript reference for more information on the methods used. It creates the REG_DWORD value ToggleTextOnSecondaryMonitor to save the toggle state of the button on the primary monitor. It uses 0 and 1 to toggle between the two states of the secondary monitor, you could of course also use higher counts for a greater variety of content.

The second HTML file is for the secondary monitor.

	<script type="text/javascript">
	//Initialize WScript Shell
	var WshShell = new ActiveXObject("WScript.Shell");
	//Get the OS type
	var OsType = WshShell.RegRead("HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Environment\\PROCESSOR_ARCHITECTURE");
	//Start checking for content changes
	window.setTimeout("CheckForContentChange()", 500);
	function CheckForContentChange(){
		if (OsType === "x86"){
			//32bit systems
				changeabletext.innerHTML = "The button to toggle the text has been clicked. <span style='color:red'>Click the button again to change to the original text.</span>";
				changeabletext.innerHTML = "This text will change if the 'Toggle text on secondary monitor' button has been clicked on the primary monitor.";
			//64bit systems
				changeabletext.innerHTML = "The button to toggle the text has been clicked. <span style='color:red'>Click the button again to change to the original text.</span>";
				changeabletext.innerHTML = "This text will change if the 'Toggle text on secondary monitor' button has been clicked on the primary monitor.";
		window.setTimeout("CheckForContentChange()", 250);
		<span id="changeabletext">This text will change if the 'Toggle text on secondary monitor' button has been clicked on the primary monitor.</span>

It uses Javascript, WScript and HTML code to read the toggle state from the registry and display one of two strings on the monitor. Instead of the simple strings of this example script you can of course use images, videos, etc. (please note that the SiteKiosk Player is based on the IE WebBrowser Control and is therefore limited to its capabilities). The Javascript setTimeout method is used to to trigger frequent checks of the Windows registry for any changes to the ToggleTextOnSecondaryMonitor value.

To see the above example code work, please copy, paste and safe each code example to a different file using an editor like Notepad. Save the HTML code for the primary monitor as primarymonitor.html, the Javascript code for the external script as externalscript.js and the HTML code for the secondary monitor as secondarymonitor.html (of course the file names are examples). All files should be placed in the HTML subfolder of your SiteKiosk installation path, e.g. C:\Program Files (x86)\SiteKiosk\Html.

Open the SiteKiosk configuration editor and go to Start Page & Browser, choose the Crome Browser and select the primarymonitor.html file as the Start Page of the Primary Monitor.


Next click on the Customize button on the same configuration page, then go to Advanced and add the external script file externalscript.js there.


Click on the Secondary Monitor tab, activate the secondary monitor, select the SiteKiosk Player and under Settings add the secondarymonitor.html.

Start SiteKiosk to see the script work.

Trigger Actions at a Specific Time and Day

The configuration of SiteKiosk allows you to run a number of common tasks (e.g. computer shutdown, monitor on/off, etc.) at specific times and days of the week by using the scheduling options. You can find these settings under Maintenance -> System / Monitor Settings in the configuration tool.

Using the script capabilities of SiteKiosk you can perform nearly any action you can think of at any given time and day of the year. The example script mainly uses standard Javascript and adds just a little bit of the SiteKiosk Object Model to perform SiteKiosk specific actions.

// This scheduler script supports two modes:
// 1) Define scheduled events that will repeat every day (everydaymode = true)
// 2) Define different scheduled events for every single day of the year (everydaymode = false)
// Only modify the configuration part of this script (lines 35 - 450).
// To use the script, open the SiteKiosk configuration, go to  Start Page & Browser -> Advanced -> Execute scriptfile and add the script there.

// Current date
var mydate = new Date();
// Minute of the last time check
var lastminute = 0;

// Initialization of the weekdays array
var sWeekDays = new Array(32);
for (i = 0; i<=31; i++)
   sWeekDays[i] = new Array(13);
   for (i2 = 0; i2<=12; i2++)
      sWeekDays[i][i2] = new Array(24);
      for (i3 = 0; i3<=23; i3++)
         sWeekDays[i][i2][i3] = new Array(60);

// Initialization of the everyday array
var sEveryDay = new Array(24);
for (i = 0; i<=23; i++) sEveryDay[i] = new Array(60);

// ------------------------------------------------------------------------------------------
// Configuration part (beginning)
// ------------------------------------------------------------------------------------------

// true:  scheduled events will repeat every day, use sEveryDay[hour][minute] = "yourfunction();"
// false: different scheduled events for every single day of the year, use sWeekDays[day][month][hour][minute] = "yourfunction();"
var everydaymode = true;

// period of time between the time checks in milliseconds
var period = 5000;

// Scheduled event will repeat every day, active if everydaymode is true
// sEveryDay[hour][minute] = "yourfunction();";
sEveryDay[13][40] = "BrowserDialogOverlayExampleFunction()";

// Different scheduled events for every single day of the year, active if everydaymode is false
// sWeekDays[day][month][hour][minute] = "yourfunction();";
// January
sWeekDays[01][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][01][15][30] = "BrowserDialogOverlayExampleFunction()";

// February
sWeekDays[01][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][02][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][01][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][01][15][30] = "BrowserDialogOverlayExampleFunction()";

// March
sWeekDays[01][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][03][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][03][15][30] = "BrowserDialogOverlayExampleFunction()";

// April
sWeekDays[01][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][04][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][04][15][30] = "BrowserDialogOverlayExampleFunction()";

// May
sWeekDays[01][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][05][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][05][15][30] = "BrowserDialogOverlayExampleFunction()";

// June
sWeekDays[01][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][06][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][06][15][30] = "BrowserDialogOverlayExampleFunction()";

// July
sWeekDays[01][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][07][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][07][15][30] = "BrowserDialogOverlayExampleFunction()";

// August
sWeekDays[01][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][08][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][08][15][30] = "BrowserDialogOverlayExampleFunction()";

// September
sWeekDays[01][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][09][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][09][15][30] = "BrowserDialogOverlayExampleFunction()";

// October
sWeekDays[01][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][10][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][10][15][30] = "BrowserDialogOverlayExampleFunction()";

// November
sWeekDays[01][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][11][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][11][15][30] = "BrowserDialogOverlayExampleFunction()";

// December
sWeekDays[01][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[02][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[03][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[04][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[05][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[06][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[07][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[08][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[09][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[10][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[11][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[12][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[13][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[14][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[15][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[16][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[17][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[18][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[19][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[20][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[21][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[22][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[23][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[24][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[25][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[26][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[27][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[28][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[29][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[30][12][15][30] = "BrowserDialogOverlayExampleFunction()";
sWeekDays[31][12][15][30] = "BrowserDialogOverlayExampleFunction()";

// This example function overlays the browser with a dialog
function BrowserDialogOverlayExampleFunction()
	mydialog = SiteKiosk.SiteKioskUI.CreateHTMLDialog();
	mydialog.URL = "https://www.provisio.com/link/WindowsIdle";
	mydialog.Closable = false;
	mydialog.CloseOnInput = true;
	mydialog.ScrollBars = false;
	mydialog.Title = false;
	mydialog.Sysmenu = false;
	mydialog.Transparency = 235;
	mydialog.Width = 1000;
	mydialog.Height = 800;

// ------------------------------------------------------------------------------------------
// Configuration part (end)
// ------------------------------------------------------------------------------------------

// Calls the event defined for the current time
function mycaller(eventID)
   mydate = new Date();
   myday = parseInt(mydate.getDate());
   mymonth = parseInt(mydate.getMonth());
   myhours = parseInt(mydate.getHours());
   myminutes = parseInt(mydate.getMinutes());
   if (myminutes != lastminute)
      if (everydaymode)
      lastminute = myminutes;

// Timer that calls the mycaller function periodically
evtid = SiteKiosk.Scheduler.AddPeriodicEvent(period, mycaller);

Use the configuration part of the script to make adjustments to the settings.

Set everydaymode to true, if you want the script to do the same task at the same time of each day, set it to false, if you want to use a different time every single day of the year and even a different task for each of those.

You can change period if you want to change how often the script checks whether the given time has been reached. The default is 5000 milliseconds which should be fine in most cases.

sEveryDay is the array used when everydaymode is true. You can set the hour (00-23) and the minute (00-59) as well as the function you want to be called when the defined time has been reached.

sWeekDays is the array used when everydaymode is false. It accepts values for the day (01-31), the month (01-12), the hour (00-23) and minute (00-59). Just as with sEverDay you assign the function you want to call at the given day and time. Note that this could be a different function or a function with different parameters for every day of the year.

In the example script both arrays use the same example function named BrowserDialogOverlayExampleFunction. The function name and what the function does is just an example to demonstrate the workings of this script, it can by nearly anything you can imagine for the kiosk project you use this script with. In the script CreateHTMLDialog is used to create an overlay, that shows a webpage over the SiteKiosk browser, e.g. for informational purposes. The method returns an SKHtmlDialog object, that allows you to configure the overlay to your needs.

Save the script as a .js file, e.g. scheduler.js, and put it in the folder ..\SiteKiosk\html. Open the SiteKiosk configuration, go to Start Page & Browser -> Advanced and add it as a script SiteKiosk should execute on startup.

Restrict Printing to Selected Websites

This time we want to look at a script that allows you to restrict printing to certain websites.

The script is using the SiteKiosk Object Model and runs as an external script. It can be used with the Chrome engine as well as the Internet Explorer engine.

To add the external script, open the SiteKiosk Configuration, go to Start Page & Browser and click on the Advanced button. In the dialog that will open, you can add an external script file. The following screenshot shows this for the Chrome engine of SiteKiosk.


To make the script work, you also need to enable printer monitoring on the Print page of the SiteKiosk Configuration.


Let's move onto the script now. Save the code below as a .js file in the HTML subfolder of your SiteKiosk installation, e.g. C:\Program Files (x86)\SiteKiosk\Html\restrictprinting.js.


var gk_PrintingAllowed = new Array();

//Add URLs you want to allow printing for
gk_PrintingAllowed[0] = "https://www.provisio.com";
//Add additional URLs here
//gk_PrintingAllowed[1] = "https://www.google.com";
//gk_PrintingAllowed[2] = "http://www.bing.com";


var gk_job;
SiteKiosk.Printer.OnNewJob = OnNewJob;

function OnNewJob(printer, job){
	gk_job = job;
	evtid = SiteKiosk.Scheduler.AddDelayedEvent(500, PrintOrNot);

function PrintOrNot(){
	var stopprinting = true;
	for(var i=0;i<gk_PrintingAllowed.length;i++){
		if(gk_job.Document.indexOf(gk_PrintingAllowed[i]) != -1){
			stopprinting = false;

		SiteKiosk.Logfile.Notification("Deleting print job because URL is not allowed for printing."); //Debug

The script uses the array gk_PrintingAllowed for all the URLs you want to allow printing from. Add additional URLs by counting up the numbers, gk_PrintingAllowed[1] = "https://www.google.com"; then gk_PrintingAllowed[2] = "http://www.bing.com"; and so on.

The print jobs are monitored using the OnNewJob event. When this is fired, we receive a JobInfo object for the specific job. We then give the job a little time to be processed by using the AddDeleyedEvent method, before calling the PrintOrNot function, where we check if the URL of the print job is in the array of allowed URLs using a simple string comparison.

If the URL is not allowed, the script writes a short notification to the SiteKiosk logs using the Notification method and then uses the Delete method of the JobInfo object.

In case you want to inform the user about the deleted print job, you might use the CreateHTMLDialog method to display a dialog.

How to trigger content on one monitor with actions on a second monitor

In the following example you have two HD screens with a 1920 x 1080 resolution. On the first screen you will be able to present Videos which are activated by buttons presented on the second screen.


First you have to select SiteCaster in the Startpage & Browser section in the tab Primary Monitor the SiteKiosk configuration.

In the tab Secondary Monitor, you have to uncheck the option Restict the mouse pointer to the first monitor browser area. Note that you don’t have to activate the secondary monitor in the Secondary monitor tab.

Then you have to adjust the SiteKiosk configuration manually as described in the devblog entry https://devblog.provisio.com/post/2019/10/29/Extend-the-SiteCaster-workspace-to-multiple-screens-(Combine-several-screens-to-one-screen).aspx to extent the a SiteCaster workspace to a resolution to 3840 x 1080.

In the next step you generate a in the SiteCaster editor a project with a 3840 px x 1080 px resolution.

Go into the View setting and open the Resolution / Zoom dialogue.

Activate the radio button Custom Width and enter 3840 px width and 1080 px height.

Then add a swap container with 1920 px x 1080 px on the left side (Screen 1) of the project view.

Add an image and two videos into the Swap container.

On the right side (Screen 2) of the project view add two images which represent the buttons to trigger the videos.

Open the properties dialogue of the first image, activate the navigation option and select the first video in the dropdown menu.

Do the same with the second image and select the second video in the dropdown menu.

Finally start SiteKiosk with the generated configuration and publish the project.

As a result, the Image in the swap container will be displayed when the system is idle. With pressing on one of the generated buttons on the second screen the corresponding video is displayed on the first screen.

Having Different Start Pages for each Browser Language

The easiest way to setup a multilanguage start page in SiteKiosk is to use the included Start Screen under Start Page & Browser in the SiteKiosk Configuration. Template 1 of the Start Screen supports different languages out of the box.

If you want to directly call different URLs based on the selected browser language you can use the following HTML page.

<!DOCTYPE html>
		<title>Multilanguage Start Page Switcher</title>
		<script type="text/javascript">
			//URLs based on their language
			var StartPage = new Array();
			StartPage[5] = "https://europa.eu/european-union/index_cs";	// Czech
			StartPage[6] = "https://europa.eu/european-union/index_da";	// Danish
			StartPage[7] = "https://europa.eu/european-union/index_de";	// German
			StartPage[8] = "https://europa.eu/european-union/index_el";	// Greek
			StartPage[9] = "https://www.usa.gov/"; // English
			StartPage[10] = "https://europa.eu/european-union/index_es"; // Spanish
			StartPage[11] = "https://europa.eu/european-union/index_fi"; // Finnish
			StartPage[12] = "https://europa.eu/european-union/index_fr"; // French
			StartPage[16] = "https://europa.eu/european-union/index_it"; // Italian
			StartPage[19] = "https://europa.eu/european-union/index_nl"; // Netherlands
			StartPage[20] = "https://www.regjeringen.no/"; // Norwegian
			StartPage[21] = "https://europa.eu/european-union/index_pl"; // Polish
			StartPage[22] = "https://europa.eu/european-union/index_pt"; // Portugese
			StartPage[24] = "https://europa.eu/european-union/index_ro"; // Romanian
			StartPage[25] = "http://government.ru/"; // Russian
			StartPage[29] = "https://europa.eu/european-union/index_sv"; // Swedish
			StartPage[37] = "https://europa.eu/european-union/index_et"; // Estonian
			StartPage[39] = "https://europa.eu/european-union/index_lt"; // Lithuanian
			StartPage[1033] = "https://www.usa.gov/"; // English US, only applies to Chrome engine
			StartPage[2057] = "https://europa.eu/european-union/index_en"; // English UK, only applies to Chrome engine
			StartPage[2222] = "https://www.un.org/"; // neutral
			//Examples of other language ids: 1 Arabic, 4 Chinese, 17 Japanese, 55 Georgian, 86 Galician
			//Default language to be used if no other language matches
			var skdefaultlanguage = 2222; // neutral entry
			//End of Configuration
				//Code for SiteKiosk IE engine
				//Get the major language id of the currently selected language
				sklanguageid = SiteKiosk.LocaleManager.LangID & 1023;
				//Code for SiteKiosk Chrome engine
				(new Function(_siteKiosk.getSiteKioskObjectModelCode()))();
				//Get the major language id of the currently selected language with special handling for US and UK English in SiteKiosk Chrome engine
				sklanguageid = _siteKiosk.objectModel.callHostFunction("system.windows.skLegacy.executeScript", "if ((SiteKiosk.LocaleManager.LangID & 1023) !== 9) return SiteKiosk.LocaleManager.LangID & 1023; else return SiteKiosk.LocaleManager.LangID;");
			function redirectBasedOnLanguage(sklanguageid){
				if (StartPage[sklanguageid] != null)
					document.location = StartPage[sklanguageid];
					document.location = StartPage[skdefaultlanguage];

Copy and paste the code to an editor like Notepad and save it as an HTML file, e.g. multilanguagestartpageswitcher.html. Put the file in the folder ..\SiteKiosk\html. Open the configuration of SiteKiosk, go to Start Page & Browser and select the file as your start page. The example works with IE and Chrome engine.

The configuration part of the above example code starts with an array that includes the language ids for the languages supported by SiteKiosk and the URLs associated with them. Change the URLs to match your needs. You may also use the file protocol for local pages.

The skdefaultlanguage includes the language id of the above array that should be used in case no matching id can be found in the array. The example uses a special neutral value, you may as well use one of the existing languages, e.g. 9 for English.

The try part of the code contains code for the IE engine. It uses the LangID property of the SiteKiosk Object Model to determine the currently selected browser language.

The catch part contains the code for the Chrome browser. The Chrome browser Object Model code (documentation available on request from support-europe@provisio.com) calls the same LangID property of the classic SiteKiosk Object Model. Note that the Chrome browser distinguishes between US and UK English. 

Once the language id has been indentified the redirectBasedOnLanguage function calls the URL associated with that id or the one that has been set as the default, if no match can be found.


The Powerful Run Executable Job Action Type of SiteRemote

An often overlooked action type of the SiteRemote job system (in your SiteRemote team choose SiteKiosk from the menu and then select the job tab) is one called Run Executable. It is a more general action type than most of the others but that is what makes it so powerful. What it allows you to do is to basically run any executable including the use of parameters.  


You can run Windows Powershell, batch files, (silent) installers, Windows system tools and so on. This allows you to administrate your SiteKiosk Windows machines in almost every possible way in addition to the SiteKiosk administration and monitoring the SiteRemote GUI already helps you with.

It is even possible to update SiteKiosk remotely with the help of the Run Executable job action type. Please contact our support for more information, because the exact method varies based on the SiteKiosk version in use.

This job action type runs on the client invisible with administrative privileges in the context of the Local System user or visible with the rights of the user that is logged in at the moment the job is executed.

If the executable you run provides a return value you can use that to show whether the job was successful or not on the SiteRemote job page. Not using this option will show the job as successful if starting the executable did not return an error.

A simple example that starts Notepad with the SiteKiosk license text would be this command line:

"c:\windows\notepad.exe" "c:\program files (x86)\SiteKiosk\license-en.txt"

If you then choose the option Visible execution with user rights, the job will start Notepad with the license text file on the SiteKiosk Windows machine, once the job has been assigned and ececuted on a client.

Please note that past DevBlog posts have described how to access 64-Bit system folders and registry paths (https://devblog.provisio.com/post/2015/11/03/Accessing-64-Bit-System-Folders-and-Registry-from-the-SiteRemote-Job-System.aspx) or how to unzip zip archives uploaded with a SiteRemote job step to a specific destination folder (https://devblog.provisio.com/post/2016/02/22/Distributing-the-SiteKiosk-Windows-Start-Screen-with-SiteRemote.aspx) all with the help of the Run Executable job action type.

Keep Additional Windows Visible when Using SiteKiosk Windows in Fullscreen Mode Without a Taskbar

This example script is intended to be used when SiteKiosk Windows runs in fullscreen mode without a taskbar. When additional windows are allowed, either browser or application windows, users can intentionally or unintentionally hit the minimize button. Without a taskbar the window is then hidden to the user.

This script will scan for minimized windows and restore them. It can be used with the Chrome and Internet Explorer browser engines of SiteKiosk Windows. It works for browser windows and windows of other applications.

Please note that you need to enable the option to 'Keep the SiteKiosk main window in the background (not TopMost)' when using the Internet Explorer browser engine of SiteKiosk Windows. The option can be found under Start Page & Browser -> Internet Explorer -> Advanced. This option is not required when using the Chrome browser engine of SiteKiosk Windows as it behaves like this by default.

The script looks like this:

//If using the Internet Explorer browser engine of SiteKiosk, please activate the option 
//Keep the SiteKiosk main window in the background (not TopMost)
//when using this script. The option can be found in the SiteKiosk configuration under
//Start Page & Browser -> Internet Explorer -> Advanced.
//The Chrome browser engine of SiteKiosk behaves like this by default.

SiteKiosk.Scheduler.AddPeriodicEvent(1000, windowWatchdog);

function windowWatchdog(){
	SKWindows = SiteKiosk.WindowList.Windows;
	for (var i = 1; i <= SKWindows.Count; ++i){
		if (SKWindows.Item(i).WindowType !== 1 && SiteKiosk.WindowList.IsMinimized(SKWindows.Item(i).Handle)){

It uses the Scheduler object of the SiteKiosk Object Model to schedule a periodic event that calls a function that checks the status of all windows every second.

The Windows collection of the WindowList object includes all existing windows. The script steps through all of them and looks for windows, that are not the main window of SiteKiosk, which would have a WindowType of 1, and are minimized.

It will then use the Restore method to make the window visible again.

Using HTML Tags to Customize Text Fields of the SiteKiosk Windows Start Screen

When using the Start Screen of SiteKiosk Windows, you can use HTML tags in text fields to customize the appearance. This allows you to create individual projects beyond what is already possible with the standard options of the Start Screen Editor.

To give an example of the possibilities, you can open the SiteKiosk Configuration tool, go to Start Page & Browser and select the Start Screen. From there, click on Customize, then on Start Screen Editor and open the editor. For this example select Template 3, which is empty by default.

Let's add a new element of the Web link type. Note that you can do this with any element that has text fields, this is usually the caption for the element.

After the Web link element has been added, edit it by opening the properties. Go to Caption and use the Text property at the top of the page. Note that on this page you can already edit the font, size and color of the complete text. But this example wants to show that you can override all of this with HTML tags. You can give each character of the default text, which is Web, a different look and even a function.

In this example change the default Text size to 50 and write this into the Text field:

<b>W</b><span style="color: yellow;font-family:cursive;font-size:22px;">e</span><span onclick="alert('Show this alert when clicking on the b character!');" style="color:red;font-size:34px;">b</span>

This will make the W bold while it keeps the defined general size, font type and color, it will make the e yellow while giving it a size of 22 pixels and assign the cursive font to it, the b will show in red with a size of 34 pixels and display an alert window when being clicked. This just demonstrates a few of the options you have, because the text field allows HTML tags to be used.

When you start SiteKiosk, the result will look like this, with an open alert window after clicking on the b character:

Create a new project template from an existing project

It is possible to make existing SiteCaster projects in SiteCaster permanently available again as templates. This entry describes how to create a template from an existing project if you have an own server.

First you have to export the corresponding project:

1. Open the project in the editor and copy the project ID from the URL.

for example:


2. Insert the project ID in the following line.

3. https://www.siteremote.net/sitecastercms/api/projects/5e7b5098415fcafc08348a01/export

4. Copy the URL

5. Open a new tab and paste the created export address – press Enter

6. Press Enter to download the zip file 

In the second part you have to modify the project folder and transfer it to a template folder:

1. Unpack the zip file.

2. Rename the content.json file located in the folder to content.original.json

3. Go to the following directory on the server:

C:\Program Files (x86)\PROVISIO\SiteRemote\Web.SiteCaster\server\projects\projectTemplates

4. Copy one of the existing template folders and paste it again.

5. Rename the folder (e.g. name of the template).

6. Replace the image file in the folder with an image file of your template, whereby the name preview must be retained and the file type has to be JPG.

7. Open the projectTemplate.manifest file in the folder with a text editor (e.g. Notepad)

8. Change the name of the template "name": "${string:StartScreenTemplate.name}", e.g. to "name": "TEST-Template”

9. Change the Project ID "projectID": "311f9e4eb2427f5ec02e32f1" in the file to create a unique new ID e.g. "projectID": "777f9e4eb2427f5ec02e32f1

10. Open the folder: 00000000000000000000

11. Delete the content of the folder

12. Add the complete content of the zip folder with the content.original.json file into the 00000000000000000000000000 folder

13. Open the SiteCaster Editor in a browser and click on the Create New Project button -> The new project template is now available

If you want to offer your template on your server in a team-specific manner, you must use the following path for the procedure described above:

C:\Program Files (x86)\SiteRemote\Common\Teams\teamStorage\<TeamId>\projectTemplates

The team ID specified in the path is individual per team and can be found on the server administration page in the tab teams.

Starting the SiteKiosk File Manager from a Custom Button in SiteKiosk Windows Chrome Browser

As a default option the SiteKiosk file manager is only available with IE-based skins. There are different ways to also start the file manager when using the Chrome browser of SiteKiosk Windows. How to start the SiteKiosk file manager when using the Chrome Browser and the Start Screen has been described here. Now we want to take a look at how to start the file manager using the custom button option.

First we need to create a local JavaScript file that takes care of the task of opening the File Manager. The code for that file can look like this:

function openFileManager(){
 //Defines the available Window styles for the File Manager window
 var WS_OVERLAPPED = 0x00000000;
 var WS_MAXIMIZEBOX = 0x00010000;
 var WS_MINIMIZEBOX = 0x00020000;
 var WS_THICKFRAME = 0x00040000;
 var WS_SYSMENU = 0x00080000;
 var WS_BORDER = 0x00800000;
 var WS_CAPTION = 0x00C00000;
 var WS_MAXIMIZE = 0x01000000;
 var WS_MINIMIZE = 0x20000000;
 var WS_POPUP = 0x80000000;
 var WS_EX_TOOLWINDOW = 0x00000080;
  //Creates the File Manager window and assigns its settings
  var mediabox = SiteKiosk.SiteKioskUI.CreateHTMLDialog();
  mediabox.URL = SiteKiosk.SiteKioskDirectory + "skins\\public\\Media\\FileManager\\Selector.html";
  mediabox.Styles = 13565952;
  mediabox.Icon = SiteKiosk.SiteKioskDirectory + "skins\\public\\Media\\FileManager\\Img\\Icons\\fms_ico.ico";
  mediabox.Width = 1024;
  mediabox.Height = 700;
  mediabox.ExStyles = 0;//
  mediabox.Border = true;
  mediabox.Type = "FileManagerDlg";
  mediabox.TopMostWindow = false;
  mediabox.CloseOnInput = false;
  mediabox.Parent = SiteKiosk.WindowList.MainWindow.SiteKioskWindow.Window;

Just copy and paste the code to an editor and save it for example as "OpenFileManager.js" at "…\SiteKiosk\Html".
Next it's time to open the SiteKiosk configuration and adding this script file at "Start Page & Browser-->Advanced-->On startup of SiteKiosk execute the following script file".

Then create an HTML file (e.g. OpenFileManager.html) with the following content and save it in the folder "...\SiteKiosk\Html":

    (new Function(_siteKiosk.getSiteKioskObjectModelCode()))();
    _siteKiosk.objectModel.callHostFunction("system.windows.skLegacy.executeScript", "SiteKiosk.ScriptDispatch.openFileManager();");            
    <!-- Body is empty as this window is only used to open the File Manager //-->

The function OpenFileManagerExt is "Using the Classic SiteKiosk Object Model in SiteKiosk Windows Chrome Browser" in combination with the "ScriptDispatch Object" from classic SiteKiosk Object Model to call the external script function "openFileManager".

Now add a button in the Chrome Browser Skin under "Start Page & Browser-->Customize-->Browser Toolbar-->Individual Buttons-->Set individual weblink or program" which calls the above HTML file.

General Note:
Which directories are displayed in the File Manager (download folder, etc.) must be specified beforehand under "Files & Downloads", while you have selected the Metro IE Skin under "Start Page & Browser".
The path for the download folder should match the download folder in the Chrome Browser skin.
Since the download folder matches with the default settings "C:\Users\Public\Documents\SiteKiosk" you normally only need to activate the File Manager and Downloads.

Finally it should look like this when the File Manager is opened: