function GetDropDownValue(ddl)
{
	var ret = null;
	if (ddl.selectedIndex > -1)
	{
		ret = ddl.options[ddl.selectedIndex].value;
	}
	return ret;
}

function GetDropDownText(ddl)
{
	var ret = null;
	if (ddl.selectedIndex > -1)
	{
		ret = new String(ddl.options[ddl.selectedIndex].innerHTML);
	}
	return ret;
}

function SetControlAttribute(ctl, attributeName, attributeValue)
{
	try
	{
		ctl.setAttribute(attributeName, attributeValue);
	}
	catch (ex)
	{
		alert(ex.message);
	}
}

function GetControlAttribute(ctl, attributeName)
{
	var ret = null;
	if (navigator.appName == 'Microsoft Internet Explorer')
	{
		ret = ctl.getAttribute(attributeName);
	}
	else 
	{
		ret = ctl.getAttribute(attributeName);			
	}

	return ret;
}

function RemoveControlAttribute(ctl, attributeName)
{
	ret = ctl.removeAttribute(attributeName);
}


function AddDropDownOption(ddl, option)
{
	try
	{
		if (navigator.appName == 'Microsoft Internet Explorer')
		{
			ddl.options.appendChild(option);
		}
		else 
		{
			ddl.options.add(option);
		}
	}
	catch (ex)
	{
		alert('AddDropDownOption', ex.message);
	}
}