// (c) 2002 LANSA
// Standard Scripts messages
// $Workfile:: std_script_messages.js      $
// $UTCDate:: 2008-07-15 22:33:11Z         $
// $Revision:: 2                           $

function StdGetMessageText(messageId)
{
	switch(messageId)
	{
	case "PPCNoForm":
		return "This browser does not support document.createElement. You must have a FORM which must be specified in the calling objects formname property.";
	case "BadHidFld":
		return "This browser does not support document.createElement. You must predefine the hidden field %1%.";
	case "BadHidFld1":
		return "document.createElement is not implemented, ";
	case "BadHidFld2":
		return " hidden field must be available in the form.";
	case "BadNum":
	    return "Invalid number.  The number must contain only digits (no more than %1% before the decimal point and no more than %2% after).";
	case "BadNum1":
		return "Allowable digits before decimal point = ";
	case "BadNum2":
		return "\nAllowable digits after decimal point = ";
	case "BadNum3":
		return "\nData will be truncated accordingly.";
	case "BadInt":
		return "Invalid integer number.";
	case "BadIntWithRange":
		return "Invalid integer number. Cannot be less than %1%, or greater than %2%.";
	case "BadInt1":
		return " Cannot be less than ";
	case "BadInt2":
		return ", or greater than ";
	case "BadFloat":
		return "Invalid floating point number!";
	case "BadDate":
		return "Invalid date!";
	case "BadDate1":
		return " is an invalid date!";
	case "BlankDate":
		return "Blank is an invalid date. Defaulting to today's date.";
	case "BlankDate2":
		return "Blank is an invalid date.";
	case "BadTime":
		return "Invalid time!";
	case "BadTime1":
		return " is an invalid time!";
	case "BlankTime":
		return "Blank is an invalid time! Defaulting to current time!";
	case "BlankTime2":
		return "Blank is an invalid time!";
	case "BadDateTime":
		return "Invalid datetime!";
	case "BadBool":
		return "Invalid value.\nValue must be \"true\" or \"false\"";
	case "BadDBCS":
		return "Converted length of characters entered is ";
	case "BadDBCS1":
		return "Only DBCS characters are allowed in this field.\n";
	case "BadDBCS2":
		return " SBCS characters have been entered.\n";
	case "BadDBCS3":
		return "SBCS characters will be removed.";
	case "BadDBCS4":
		return "Either all DBCS characters or all SBCS characters ";
	case "BadDBCS5":
		return "are allowed in this field.\n";
	case "BadDBCS6":
		return " SBCS characters have been entered.\n";
	case "BadDBCS7":
		return " DBCS characters have been entered.\n";
	case "BadDBCS8":
		return "Please modify field data accordingly.";
	case "BadDBCS9":
		return "Only SBCS characters are allowed in this field.\n";
	case "BadDBCS10":
		return " DBCS characters have been entered.\n";
	case "BadDBCS11":
		return "DBCS characters will be removed.";
	case "BadDBCS12":
		return "\nwhich exceeds the maximum allowable length of ";
	case "BadDBCS13":
		return "\nData will be truncated accordingly.";
	case "BadLength1":
		return "Maximum characters reached.";
	case "NoXMLHttpRequest":
		return "XMLHttpRequest not supported by this browser.";
	case "Processing1":
		return "Processing";
	case "Done1":
		return "Done";
	}
	alert("Message text for message id " + messageId + " not found!");
	return null;
}

function StdGetMessageTextArr(messageId)
{
	switch(messageId)
	{
	case "DaysOfWeek":
		return new Array("Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun");
	break;
	case "Months":
		return new Array("January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December");
	break;
	}
	alert("Message text array for message id " + messageId + " not found!");
	return null;
}
