ImageFile Property



 
The ImageFile property contains the absolute or relative path to the animation's source image.


Syntax

    document.all["id_name"].ImageFile [=String] 
Possible Values
    String that specifies or retrieves the path to the image file.

    The property is read/write.
Remarks
    The specified path must be either absolute or relative to SiteKiosk's installation directory. If this property is set, the animation image will be reloaded immediately.
Examples
    The following example reads the ImageFile property and shows it in an alert window.

    <html>
    <head>
    <SCRIPT TYPE="text/javascript">
    function changeAnimation()
    {
    	var path1="skins\\default\\img\\buttonbar.png";
    	var path2="skins\\default\\img\\anilogo.png";
    	document.all["id_SKAnimateControl"].Stop();
    	document.all["id_SKAnimateControl"].Reset();
    	if(document.all["id_SKAnimateControl"].ImageFile==path1)
    	document.all["id_SKAnimateControl"].ImageFile=path2;
    	else document.all["id_SKAnimateControl"].ImageFile=path1;
    }
    </SCRIPT>
    </head>
    <body>
    <div onclick="changeAnimation()">Change Animation!</div>
    <OBJECT id="id_SKAnimateControl" style="width:65px; height:65px; 
    border-width:0px; margin-right:0px; margin-bottom:5px; 
    margin-top:5px; " 
    classid="CLSID:D061BD69-BEDF-4A1C-B890-9D6E784CA25E">
    	<PARAM NAME="ImageFile" VALUE=
    	"skins\default\img\buttonbar.png">
    	<PARAM NAME="ImageWidth" VALUE="65">
    	<PARAM NAME="TimerInterval" VALUE="100">
    	<PARAM NAME="UseAlpha" VALUE="0">
    	<PARAM NAME="SrcAlpha" VALUE="0">
    	<PARAM NAME="BackgroundColor" VALUE="0">
    	<PARAM NAME="Transparent" VALUE="0">
    </OBJECT>
    <SCRIPT TYPE="text/javascript">
    function id_SKAnimateControl::Click()
    {
    	document.all["id_SKAnimateControl"].Start();
    }
    function id_SKAnimateControl::DblClick()
    {
    	document.all["id_SKAnimateControl"].Stop();
    	document.all["id_SKAnimateControl"].Reset();
    	document.all["id_ImageCounter"].innerHTML=0;
    }
    </SCRIPT>
    </body>
    </html>

Applies to
    SiteKiosk v5.0 (and later versions).

Back to top