Tip: Retrieving the value of an index from the ID and IDUnit

var getIndexFromIDAndIDUnit = function(pParameters, idIndex, idUnit){

	var listIndex = getIndexesFromID(pParameters, idIndex);

	if(listIndex != null){
		for(var i=0;i<listIndex.length;i++){
			if(listIndex[i].idUnit == idUnit)
				return getTextFromIndexInfo(listIndex[i]);
		}
	}
	return "";
};