function Trim(str) {
	var count = str.length, len = count, st = 0
    while ((st < len) && (str.charAt(st) <= ' ')) st++
    while ((st < len) && (str.charAt(len - 1) <= ' ')) len--

    return ((st > 0) || (len < count)) ? str.substring(st, len) : str   
}


// µ¥ÀÌÅ¸ À¯È¿¼º Ã¼Å©
function isValidate(obj,msg,chk) {
	if(chk == true) {
		if(Trim(obj.value).length < 1) {
			alert(msg);
			obj.value = "";
			obj.focus();
			return false;
		}
		else {		
			obj.value = Trim(obj.value);
			return true;
		}
	}
	else {
		return true;
	}
}



function upKey(T_value,T_length,N_value){

	if(T_value.length == T_length){
		N_value.focus()
	}
}


function checkNumber() {

	var objEv = event.srcElement;
	var numPattern = /([^0-9.])/;
	numPattern = objEv.value.match(numPattern);
	
	if(numPattern != null) {

		alert("¼ýÀÚ¸¸ ÀÔ·Â°¡´ÉÇÕ´Ï´Ù.");
		objEv.value="";
		objEv.focus();

		return false;
	}
}