I want to click on the map and then update a label with the returned values. How do I trap the value and update the label without posting back the whole page? I am trying to send it through a click on the client to a postback. Basically I am calling a server side function from javascript and need it to update a label that is in an update panel. Has someone run into this before?
if (idResult.layerName === "Stations") {
//run search for station
var feature = idResult.feature;
var template = new esri.InfoTemplate("", "Station: ${LOCATION}");
feature.setInfoTemplate(template);
document.getElementById('HiddenStation').value = idResult.value;
var button = document.getElementById('GetDocsStation');
button.click();
<div id="map" dojotype="dijit.layout.ContentPane" class="roundedCorners" region="center"></div>
<asp:UpdatePanel ID="UP1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div style="display: none;">
<asp:Button id="GetLineDocs" runat="server" OnClick="GetDocsLine_Click"/>
</div>
<div style="display: none;">
<asp:Button id="GetDocsStation" runat="server" OnClick="GetDocsStation_Click"/>
</div>
<asp:Label id="SearchLBL" runat="server" Text="Feature Name: "/>
</ContentTemplate>
</asp:UpdatePanel>