if (typeof(document.images['butData'])=='undefined') {
	bHasData=false;
} else {
	bHasData=true;

}

function ChangeTimeframes(fname) {
		for (i=0; i < document.forms[fname].optTimeframe.length; i++) {
			if (document.forms[fname].optTimeframe[i].checked) {
				nTimeFrameIndex=document.forms[fname].optTimeframe[i].value;
				break;
			}
		}
		var sChartFileName=currentchart+nTimeFrameIndex+maxid;
		var sChartFileName=sChartFileName + '.png'
		document.images['indeximage'].src='/images1/' + sChartFileName;
	return false;
}

function LoadThumbnail(sChartName_w, sChartName_m, sChartName_y, sNewLocation,fname) {
	for (i=0; i < document.forms[fname].optTimeframe.length; i++) {
		if (document.forms[fname].optTimeframe[i].checked) {
			var sTimeframe=document.forms[fname].optTimeframe[i].value;
			break;
		}
	}
	switch (sTimeframe.toUpperCase()){
		case "W" : 
			sChartName=sChartName_w;
			break;		
		case "Y" : 
			sChartName=sChartName_y;
			break;		
		case "M" : 
			sChartName=sChartName_m;
			break;		
		default : 
			sChartName=sChartName_m;
			break;		
	}
	
     currentchart=sNewLocation;	
	document.images['indeximage'].src='/images1/'+sChartName+'.png'

	if (sNewLocation) {
		movePageMarker(sNewLocation) 
	}
	return false;
}


function movePageMarker(sNewLocation) {
document.images[sLastLocation].src="images/blank.gif";			
document.images[sNewLocation].src="images/ActiveChart.gif";			
sLastLocation=sNewLocation;
return false;
}



