function SetBuildingId(formId, elementid, elementValue)
  {
    var theElement = document.getElementById(elementid);
    var theForm = document.getElementById(formId); 
    theElement.value = elementValue;

    if (elementValue != 2)
      {
      var msg = 
        "This buidling is currently not available to monitor.  " +
        "Please select another building." 
      alert(msg); 
      }
    else
      {
      theForm.submit(); 
      }
  }
