function ShowHideMestGiftLink(listMest, textboxGift, linkbuttonMest, emptyItemText, gridMestLabel)
{
	// get textbox gift
	var textBox = getElementById(textboxGift);
	// get the linkbutton for mest details
	var linktButton = getElementById(linkbuttonMest);
	
	if ((textBox) && (linkbuttonMest))
	{
		// get the selected item text
		var text = getItemTextOfSelectedIndex(listMest);
		
		if (text == emptyItemText)
		{
			// the none item is selected so hide gift textbox and linkbutton
			textBox.value = 0;
			hideElement(textboxGift);
			hideElement(linkbuttonMest);
			//hideElement(gridMestLabel);
			//hideElement(gridMestLabel + "Unit");
		}
		else
		{
			// show the gift textbox and linkbutton
			showElement(textboxGift);
			showElement(linkbuttonMest);
			//showElement(gridMestLabel);
			//showElement(gridMestLabel + "Unit");
		}
	}
}

function ChangeUitrijMethode()
{
	var object = window.event.srcElement

	//alert(object);
	if (object.tagName != "INPUT" || object.type != "radio")
	return

	// update de oogstmethode aan de hand van de mestgroep
	var comb=getElementById('detailsOMPartij_DropdownlistOMMethode');
	comb.options[0]=null;
	comb.options[1]=null;
	
	if (object.value == 'vloeibaar')
	{
		comb.options[0]=new Option('Zodebemesting','ZB');
		comb.options[1]=new Option('Sleepvoeten','SV');
	}
	if (object.value == 'vast')
	{
		comb.options[0]=new Option('Bovengronds','BG');
	}
}

function ShowHideKMUrl(show)
{
	if (show == '1')
		showElement ('row102');
	else
		hideElement ('row102');
}




