
/*
Interactive Image slideshow with text description
By Christian Carlessi Salvadó (cocolinks@c.net.gt). Keep this notice intact.
Visit http://www.dynamicdrive.com for script
*/

g_fPlayMode = 1;
g_iimg = -1;
g_imax = 0;
g_ImageTable = new Array();

////configure below variables/////////////////////////////

//configure the below images and description to your own. 
g_ImageTable[g_imax++] = new Array ('Navigation','accounting/sm_Main.jpg','accounting/Main.jpg','SharpeSoft Accounting features Outlook&trade;-style navigation including the ability to move, resize, and hide navigation buttons');
g_ImageTable[g_imax++] = new Array ('General Ledger : Chart of Accounts','accounting/sm_ChartOfAccounts.jpg','accounting/ChartOfAccounts.jpg','This window lets you setup your chart of accounts and review account settings');
g_ImageTable[g_imax++] = new Array ('Payroll : Unions','accounting/sm_Payroll_Unions.jpg','accounting/Payroll_Unions.jpg','This window allows you to setup the various Unions you contract with and setup their local chapters. You can then setup burdens and fringes for each');


//extend the above list as desired
g_dwTimeOutSec=2

////End configuration/////////////////////////////

function ChangeImage(fFwd)
{
if (fFwd)
{
if (++g_iimg==g_imax)
g_iimg=0;
}
else
{
if (g_iimg==0)
g_iimg=g_imax;
g_iimg--;
}
Update();
}

function getobject(obj){
if (document.getElementById)
return document.getElementById(obj)
else if (document.all)
return document.all[obj]
}

function Update(){
getobject("_Ath_Img_Title").innerHTML = g_ImageTable[g_iimg][0];
getobject("_Ath_Slide").src = g_ImageTable[g_iimg][1];
getobject("_Ath_FileName").innerHTML = g_ImageTable[g_iimg][3];


//getobject("_Ath_Img_X").innerHTML = g_iimg + 1;
//getobject("_Ath_Img_N").innerHTML = g_imax;
}

function Play()
{
// added
ChangeImage(true);


g_fPlayMode = !g_fPlayMode;
}
function OnImgLoad()
{
if (g_fPlayMode)
window.setTimeout("Tick()", g_dwTimeOutSec*1000);

}
function Tick() 
{
if (g_fPlayMode)
Next();
}
function Prev()
{
ChangeImage(false);
}
function Next()
{
ChangeImage(true);
}

if (document.getElementById||document.all)
window.onload=Play