Tuesday, 11 October 2011

how to use Classic Ajax

  function SendAjaxRequestProcDescription() {

            var oXMLHTTP = null;

            if (window.XMLHttpRequest)
                oXMLHTTP = new XMLHttpRequest();
            else if (window.ActiveXObject)
                oXMLHTTP = new ActiveXObject("Microsoft.XMLHTTP");
            var sURL = "PatientDetails.aspx?proccode=" + $("#ContentPlaceHolder2_txtLeftProcCode").val()

            var nocache = "&nocache=" + new Date();
            oXMLHTTP.open("Get", sURL + nocache, false);

            oXMLHTTP.send(null);
            $("#ContentPlaceHolder2_txtLeftProcDescription").val(oXMLHTTP.responseText);

            return false;

        }


 if (Request.QueryString["proccode"] != null)
            {
}

No comments:

Post a Comment