function ajaxFunction(field, page)
{
   var xmlHttp;

   try
   {
      // Firefox, Opera 8.0+, Safari
      xmlHttp=new XMLHttpRequest();
   }
   catch (e)
   {
      // Internet Explorer
      try
      {
         xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
      }
      catch (e)
      {
         try
         {
            xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
         }
         catch (e)
         {
            alert("erro");
            return false;             
         }
      }
  }

  xmlHttp.onreadystatechange=function()
  {
    if(xmlHttp.readyState==4)
    {
      field.value=xmlHttp.responseText;
    }
  }
    xmlHttp.open("GET", page+".asp?abertura="+document.form.abertura.value+"&minima="+document.form.minima.value+"&maxima="+document.form.maxima.value+"&fechamento="+document.form.fechamento.value+"&pivot="+document.form.pivot.value,true);
  xmlHttp.send(null);  }
