var newWin = null; 

function popUp(strURL, strType, strHeight, strWidth) { 
 if (newWin != null && !newWin.closed) 
   newWin.close(); 
 var strOptions=""; 
 if (strType=="console") 
   strOptions="resizable,height="+ 
     strHeight+",width="+strWidth; 
 if (strType=="fixed") 
   strOptions="status,height="+ 
     strHeight+",width="+strWidth; 
 if (strType=="elastic_no_menu") 
	strOptions="scrollbars,"+ 
     "resizable,height="+ 
     strHeight+",width="+strWidth; 
 if (strType=="elastic") 
   strOptions="toolbar,menubar,scrollbars,"+ 
     "resizable,location,height="+ 
     strHeight+",width="+strWidth; 
 newWin = window.open(strURL, 'newWin', strOptions); 
 newWin.focus(); 
}

function resetTxtAddress() 
{
	/*
	if(window.event.srcElement.value == "(This postcode returns no address)") {
		window.event.srcElement.style.color = "#000000";
		window.event.srcElement.value = "";
	*/
	if(document.Form1.elements['txtAddress'].value == "(This postcode returns no address)") 
	{
		//get rid of the bug message if exist
		document.Form1.elements['txtAddress'].value = "";
	}
	
	//reset color back to black no matter what
	document.Form1.elements['txtAddress'].style.color = "#000000";
}