﻿
function SwapImage(imageID, newImage)
{
    document.getElementById(imageID).src = newImage;
}


function GetDate(CtrlName)    
{   

	/****************************************************      
	Use Javascript method (window.open) to PopUp a new window    
	which contain a Calendar Control. In the meantime, we'll    
	pass the Parent Form Name and Request Control Name in the QueryString!     
	 *****************************************************/        
	 ChildWindow = window.open('http://www.matrikon.com/controls/Calendar.aspx?FormName=' + document.forms[0].name + '&CtrlName=' + CtrlName, "PopUpCalendar", "width=152, height=186, top=725, left=375, toolbars=no, scrollbars=no, status=no, resizable=no");   
	 
 } 
 
function CheckWindow()   
{      
	ChildWindow.close();   
}

function ReturnDate()
{

   window.opener.document.forms["<%= strFormName %>"].elements["<%= strCtrlName %>"].value = "<%= strSelectedDate %>";
   window.close();

}
        
function Close()
{
   window.close();
}

function SwapTap(Content_One, Content_Two, Content_Three, imageID, newImage, imageID2, newImage2, imageID3, newImage3)
{
			
	document.getElementById(imageID).src = newImage;
	
	document.getElementById(imageID2).src = newImage2;
	
	document.getElementById(imageID3).src = newImage3;
	
    var elem1 = document.getElementById(Content_One);
	elem1.style.display = 'block'  
	
    var elem2 = document.getElementById(Content_Two);
    elem2.style.display = 'none'   
    
    var elem3 = document.getElementById(Content_Three);
    elem3.style.display = 'none'      
}


