function checkAnalytics(form)	// check if form is suitable for submission
	{
		var FieldsArray = new MakeArray(17);
		
		FieldsArray [0] 	= 	form.scoreNormLess.value;
		FieldsArray [1] 	= 	form.scoreNormMore.value;
		FieldsArray [2] 	= 	form.scoreSmoothLess.value;
		FieldsArray [3] 	= 	form.scoreSmoothMore.value;
		FieldsArray [4] 	= 	form.priceCloseLess.value;
		FieldsArray [5] 	= 	form.priceCloseMore.value;
		FieldsArray [6] 	= 	form.day40high.value;
		FieldsArray [7] 	= 	form.day40low.value;
		FieldsArray [8] 	= 	form.day80high.value;
		FieldsArray [9] 	= 	form.day80low.value;
		FieldsArray [10] 	= 	form.day150high.value;
		FieldsArray [11] 	=	form.day150low.value;
		FieldsArray [12] 	= 	form.gnLs.value;
		FieldsArray [13] 	= 	form.Volume.value;
		FieldsArray [14] 	= 	form.numTrades.value;
		FieldsArray [15] 	= 	form.MaxResult.value;
		FieldsArray [16] 	= 	form.ValVolume.value;
					
		var FieldsNamesArray = new MakeArray (17);
		FieldsNamesArray [0] = "Lower Score"
		FieldsNamesArray [1] = "Upper Score"
		FieldsNamesArray [2] = "Lower Smoothed Score"
		FieldsNamesArray [3] = "Upper Smoothed Score"
		FieldsNamesArray [4] = "Lower Price Indicator Query"
		FieldsNamesArray [5] = "Upper Price Indicator Query"
		FieldsNamesArray [6] = "40 Day High";
		FieldsNamesArray [7] = "40 Day Low";	
		FieldsNamesArray [8] = "80 Day High";
		FieldsNamesArray [9] = "80 Day Low";
		FieldsNamesArray [10] = "150 Day High";	
		FieldsNamesArray [11] = "150 Day Low";	
		FieldsNamesArray [12] = "Gain/Loss Value";
		FieldsNamesArray [13] = "Volume";
		FieldsNamesArray [14] = "Trades";	
		FieldsNamesArray [15] = "Maximum Results To Return";	
		FieldsNamesArray [16] = "$ Value Volume";	
		
		for (var counter = 0; counter < 17; counter++)
			{
				 for (var counter2 = 0; counter2 < FieldsArray[counter].length; counter2++)
				 	{
					 if ( ( (FieldsArray[counter].substring(counter2,counter2+1) > "9") || (FieldsArray[counter].substring(counter2,counter2+1) < "0") ) && (FieldsArray[counter].substring(counter2,counter2+1) != "-") && (FieldsArray[counter].substring(counter2,counter2+1) != ".") )
				 			 {
			  					 alert("The " + FieldsNamesArray[counter] + " field requires a numeric entry.");
								 return false;
							 }
					}
			}

		for (var counter = 0; counter < 4; counter++)
			{
			
				if ((FieldsArray[counter]-0) < 0)
					 {
			  			 alert("The " + FieldsNamesArray[counter] + " field requires a positive value.");
			  			 return false;
					 }
			}		
			
		if ( (FieldsArray[0] != "" && FieldsArray[1] != "") && ( (FieldsArray[0]-0) > (FieldsArray[1]-0) ) )
			{
				alert ("The lower score can't be bigger than the higher score.");
			 	return false;
			}		
			
		if ( (FieldsArray[2] != "" && FieldsArray[3] != "") && ( (FieldsArray[2]-0) > (FieldsArray[3]-0) ) )
			{
				alert ("The lower smoothed score can't be bigger than the higher smoothed score.");
			 	return false;
			}	
			
		if ( (FieldsArray[4] != "" && FieldsArray[5] != "") && ( (FieldsArray[4]-0) > (FieldsArray[5]-0) ) )
			{
				alert ("The lower price can't be bigger than the higher price.");
			 	return false;
			}	

		if ( (FieldsArray[15] < 1) || (FieldsArray[15] > 999) )
			{
				alert("You must enter a Rows Returned value between 1-999 to continue.");
				return false;
			}

		return true;		
	
	
	}
	
	
	
	
	function MakeArray ()
	{
		this.length = MakeArray.arguments.length;
	
	  	for (var i = 0;i<this.length;i++)
	  		this [i]="";
	}
