Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

have a small problem with XMLHttpRequest.open

$
0
0

I use master page/content page

When I have this function CallServerForUpdate in the external js library there is problem with xmlRequest.open because
when I run it says CallServerForUpdate not defined.

When I have this function CallServerForUpdate local in the content page averything works as it should
I have the master page in this location C:\Users\tony\programmering\aspNet\Gotland\Environment_Crime
I have the content page in this location C:\Users\tony\programmering\aspNet\Gotland\Environment_Crime\coordinator
I have the external js file in this location C:\Users\tony\programmering\aspNet\Gotland\Environment_Crime\js

I have the ashx file GoogleMapCallbackHandler.ashx in the same folder as the master page

The site root folder is this location C:\Users\tony\programmering\aspNet\Gotland\Environment_Crime

I must say this isn't a huge problem because I just put this small java script function local as I said before.

But it would also be great to know why I can't have the CallServerForUpdate in the external java script library

Any suggestion will be helpful ?

function CallServerForUpdate()
    {
        var  latlng = latitud + "$" + longitud;
        var caseID = document.getElementById("ContentPlaceHolder2_arendeDetaljUsrCtrl_lblID").innerHTML;
        xmlRequest.open("GET", "<%=Page.ResolveUrl("~/GoogleMapCallbackHandler.ashx?")%>caseID=" + caseID + "&latlng=" + latlng, true);
 
        xmlRequest.onreadystatechange = ApplyUpdate;
        xmlRequest.send(null);
    }

//Tony


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>