
function MoveOn(moveFrom, moveTo)
{
	var a = document.getElementById(moveFrom);
	var b = document.getElementById(moveTo);

	if(a && b)
	{
		if(a.value.length == 3)
		{	
			b.focus();
		}
	}
}

function ShowCountry(theLabel, theDDL, hdnISO)
{
    var a = document.getElementById(theLabel);
    var b = document.getElementById(theDDL);
    var c = document.getElementById(hdnISO);   
    if(a && b)
    {        
        var selValue = b.options[b.selectedIndex].value;
        var mySplitResult = selValue.split(",");
        
        /*if(theIndex > -1)
        {
            var theLength = selValue.length;

            a.innerText = selValue.substring(theIndex+1,(theLength-theIndex)+1);
        }
        else
        {
            a.innerText = '';
        }*/
        
        a.innerText = '';
        if (mySplitResult[1] != '')
        {
            a.innerText =  mySplitResult[1];
        }

        if (mySplitResult[2] != '')
        {
            c.value =  mySplitResult[2];
        }
    }
}

function TrimZero(theTextBox)
{
    var a = document.getElementById(theTextBox);

    if(a)
    {
        if(a.value.length == 1)
        {       
            if(a.value == '0')
            {
                a.value = '';
            }
        }
    }
}