function PrintThisPage(strid) 
{ 
   var sOption="toolbar=yes,location=no,directories=yes,menubar=yes,"; 
       sOption+="scrollbars=yes,width=750,height=600,left=100,top=25"; 

	var sWinHTML = '';
	
	var strid_array = strid.split(",");
	for (var loop=0; loop < strid_array.length; loop++)
	{
		try
		{
			sWinHTML = sWinHTML + document.getElementById(strid_array[loop]).innerHTML; 
		}
		catch(ex){}
	
	}

//   var sWinHTML = document.getElementById(strid).innerHTML; 
   
   var winprint=window.open("","",sOption); 
       winprint.document.open(); 
       winprint.document.write('<html><head><style>.ClaimFormName {background-color:#e0e0e0;	font-family:verdana;	font-size:12px;	color:black;	font-size:12px;	padding:2px;	text-align:left;}INPUT.ClaimFormField {font-family: verdana;	font-size: 12px;	background-color:white;	border:1px solid #666666;}SELECT.ClaimFormField {	font-family: verdana;	font-size: 12px;	background-color:white;	border:1px solid #666666;}TEXTAREA.ClaimFormField {	font-family: verdana;	font-size: 12px;	background-color:white;	border:1px solid #666666;}.formTitle {	font-size:14px;	font-weight:bolder;	font-family:Verdana, Arial, sans-serif;	color:#000000;}INPUT.ClaimFormFieldDisabled {	font-family: verdana;	font-size: 12px;	background-color:#ffffff;	border:1px solid #666666;}TEXTAREA.ClaimFormFieldDisabled {	font-family: verdana;	font-size: 12px;	background-color:#ffffff;	border:1px solid #666666;}textarea {width:400px;height:auto; overflow-y:visible;}</style></head><body>'); 
       winprint.document.write(sWinHTML);          
       winprint.document.write('</body></html>'); 
       winprint.document.close(); 
       winprint.focus();
	   winprint.print();
	   winprint.close();
}

function PrintThisPage_MachineCard(strid)
{ 
   var sOption="toolbar=yes,location=no,directories=yes,menubar=yes,"; 
       sOption+="scrollbars=yes,width=750,height=600,left=100,top=25"; 

	var sWinHTML = '';
	
	var strid_array = strid.split(",");
	for (var loop=0; loop < strid_array.length; loop++)
	{
		try
		{
			sWinHTML = sWinHTML + document.getElementById(strid_array[loop]).innerHTML; 
		}
		catch(ex){}
	
	}

//   var sWinHTML = document.getElementById(strid).innerHTML; 
   
   var winprint=window.open("","",sOption); 
       winprint.document.open(); 
       winprint.document.write('<html><head><style>.ClaimFormName {background-color:#e0e0e0;	font-family:verdana;	font-size:12px;	color:black;	font-size:12px;	padding:2px;	text-align:left;}INPUT.ClaimFormField {font-family: verdana;	font-size: 12px;	background-color:white;	border:1px solid #666666;}SELECT.ClaimFormField {	font-family: verdana;	font-size: 12px;	background-color:white;	border:1px solid #666666;}TEXTAREA.ClaimFormField {	font-family: verdana;	font-size: 12px;	background-color:white;	border:1px solid #666666;}.formTitle {	font-size:14px;	font-family:Verdana, Arial, sans-serif;	color:#000000;}INPUT.ClaimFormFieldDisabled {	font-family: verdana;	font-size: 12px;	background-color:#ffffff;	border:1px solid #666666;}TEXTAREA.ClaimFormFieldDisabled {	font-family: verdana;	font-size: 12px;	background-color:#ffffff;	border:1px solid #666666;}textarea {width:400px;height:auto; overflow-y:visible;}</style></head><body>'); 
	  var now = new Date();
	  var today = (now.getMonth()+1) + '/' + now.getDate() + '/' + now.getYear();
	   var heading = '<table align=center border=0 cellpadding=0 cellspacing=0><tr><td align=center class=formTitle>Kalmar RT Center LLC<br/></td></tr><tr><td align=center class=formTitle><strong>USMC RT 240 MACHINE CARD</strong></td></tr><tr><td align=center class=formTitle>Date Printed ' + today + '</td></tr></table>'
	   winprint.document.write(heading);
	   winprint.document.write('<hr size=1 color=#e0e0e0 />');
       winprint.document.write(sWinHTML);          
	   winprint.document.write('<hr size=1 color=#e0e0e0 />');
	   //winprint.document.write(heading);
       winprint.document.write('</body></html>'); 
       winprint.document.close(); 
       winprint.focus();
	   winprint.print();
	   winprint.close();
}

function PrintThisPage_WarrantyClaim(strid) 
{ 
   var sOption="toolbar=yes,location=no,directories=yes,menubar=yes,"; 
       sOption+="scrollbars=yes,width=750,height=600,left=0,top=25"; 


	var sWinHTML;
	var sHTML;
	var s0;
	var codeArray = new Array();
	var strid_array = strid.split(",");
	for (var loop=0; loop < strid_array.length; loop++)
	{
		try
		{
			codeArray[loop] = document.getElementById(strid_array[loop]).innerHTML;
		}
		catch(ex){}
	
	}
	
	
	//populate left side html
	sWinHTML = "<table border='0' cellspacing='0' cellpadding='0'><tr><td valign='top'>";
	sWinHTML = sWinHTML + codeArray[0];
	sWinHTML = sWinHTML + "</td>";
	
	
	//populate right side html
	sWinHTML = sWinHTML + "</td><td valign='top'>";
	sWinHTML = sWinHTML + codeArray[1];
	sWinHTML = sWinHTML + "</td></tr>";
	
	sWinHTML = sWinHTML + "<tr><td>&nbsp;</td></tr>";
	
	//populate 1st row of tables
	sWinHTML = sWinHTML + "<tr><td valign='top><span style='formTitle'>Parts Expenses</span><br>";
	sWinHTML = sWinHTML + codeArray[2];
	sWinHTML = sWinHTML + "</td>";
	
	sWinHTML = sWinHTML + "<td valign='top'><span style='formTitle'>Labor Charges</span><br>";
	sWinHTML = sWinHTML + codeArray[3];
	sWinHTML = sWinHTML + "</td></tr>";
	
	sWinHTML = sWinHTML + "<tr><td>&nbsp;</td></tr>";
	
	//populate 2nd row of tables
	sWinHTML = sWinHTML + "<tr><td valign='top'><span style='formTitle'>3rd Party Service Charges</span><br>";
	sWinHTML = sWinHTML + codeArray[4];
	sWinHTML = sWinHTML + "</td>";
	
	sWinHTML = sWinHTML + "<td valign='top'><span style='formTitle'>Travel Costs</span><br>";
	sWinHTML = sWinHTML + codeArray[5];
	sWinHTML = sWinHTML + "</td></tr>";
	
	sWinHTML = sWinHTML + "</table>";
   
   var winprint=window.open("","",sOption); 
       winprint.document.open(); 
       //winprint.document.write('<html><head><LINK href=""/include/style.css"" rel=Stylesheet><style>textarea {width:400px;height:auto; overflow-y:visible;}</style></head><body>'); 
	  winprint.document.write('<html><head><style>.ClaimFormName {background-color:#FFFFFF;	font-family:verdana;	font-size:12px;	color:black;	font-size:12px;	padding:2px;	text-align:left;}INPUT.ClaimFormField {font-family: verdana;	font-size: 12px;	background-color:white;border:0px none #FFFFFF;}SELECT.ClaimFormField {	font-family: verdana;	font-size: 12px;	background-color:white;border:0px none #FFFFFF;} TEXTAREA.ClaimFormField {	font-family: verdana;	font-size: 12px;	background-color:white;border:0px none #FFFFFF;}.formTitle {	font-size:14px;	font-family:Verdana, Arial, sans-serif;	color:#000000;}INPUT.ClaimFormFieldDisabled {	font-family: verdana;	font-size: 12px;	background-color:#ffffff;border:0px none #FFFFFF;}TEXTAREA.ClaimFormFieldDisabled {	font-family: verdana;	font-size: 12px;	background-color:#ffffff; border:0px none #FFFFFF;}textarea {width:auto;height:auto; overflow-y:visible;border:0px none #FFFFFF;}</style></head><body>');
	   var now = new Date();
	   var today = (now.getMonth()+1) + '/' + now.getDate() + '/' + now.getYear();
	   var heading = '<table align=center border=0 cellpadding=0 cellspacing=0><tr><td align=center class=printTitle>Kalmar RT Center LLC<br/></td></tr><tr><td align=center class=printTitle><strong>USMC RT 240 WARRANTY CLAIM FORM</strong></td></tr><tr><td align=center class=printTitle>Date Printed ' + today + '</td></tr></table>'
	   winprint.document.write(heading);
	   winprint.document.write('<hr size=1 color=#BDAB79 />');
       winprint.document.write(sWinHTML);          
	   winprint.document.write('<hr size=1 color=#BDAB79 />');
       winprint.document.write('</body></html>'); 
       winprint.document.close(); 
       winprint.focus();
	   winprint.print();
	   winprint.close();
}





function toggleLayer(whichLayer,buttonID)
{
	if (document.getElementById)
	{
		// this is the way the standards work
		var style2 = document.getElementById(whichLayer).style;
		style2.display == "none" ? style2.display = "block" : style2.display = "none";
		var btn = new getObj(buttonID);
		btn.obj.value == "show details >>" ? btn.obj.value = "<< hide details" : btn.obj.value = "show details >>";
	}
	else if (document.all)
	{
		// this is the way old msie versions work
		var style2 = document.all[whichLayer].style;
		style2.display == "none" ? style2.display = "block" : style2.display = "none";
		var btn = new getObj(buttonID);
		btn.obj.value == "show details >>" ? btn.obj.value = "<< hide details" : btn.obj.value = "show details >>";
	}
	else if (document.layers)
	{
		// this is the way nn4 works
		var style2 = document.layers[whichLayer].style;
		var btn = new getObj(buttonID);
		btn.obj.value == "show details >>" ? btn.obj.value = "<< hide details" : btn.obj.value = "show details >>";
	}
//	alert("done!");
}

function getObj(name)
{
  if (document.getElementById)
  {
  	this.obj = document.getElementById(name);
	this.style = document.getElementById(name).style;
  }
  else if (document.all)
  {
	this.obj = document.all[name];
	this.style = document.all[name].style;
  }
  else if (document.layers)
  {
   	this.obj = document.layers[name];
   	this.style = document.layers[name];
  }
}
