Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>It looks like your string has a newline in it (right after "CALIBRATION GROUP EXPLANATION"). This will be HTML-encoded in your tag; however, in the server-side evaluation of <code>GList.Value</code>, it will be converted to a newline, which is not escaped by <code>HtmlEncode</code>.</p> <p>Because of this, you have a newline in your string literal in the resulting JS. This is not valid.</p> <p>Do away with the server tags and change your Javascript to this:</p> <pre><code>&lt;script type="text/javascript"&gt; $(document).ready(function () { displayGageInfo($('#Glist').val()); }); &lt;/script&gt; </code></pre> <p>This will avoid the nasty business of dynamically generating string literals in code blocks and let your client-side code be concerned with doing your client-side processing.</p> <p>Additionally, your inline code will execute too late to actually populate the value in your hidden field. I expect that if you examine your rendered markup, the hidden field will still have no value after it has been loaded. This is because server tags are executed <strong>after</strong> the <code>PreRender</code> event, which is your last chance to make changes to controls. You need to run this code earlier in the page lifecycle (try <code>Page_Load</code>):</p> <pre><code>&lt;script runat="server"&gt; protected void Page_Load(object sender, EventArgs e) { var reader = new GAGEmobile.Models.ReadXML(); var data = reader.getDataFromXML("https://gagemobile- demo.servicebus.windows.net/gagemobile/gage/15/sample/david/blah"); this.Glist.Value = data; } &lt;/script&gt; </code></pre> <p>You will also need to switch on <code>AutoEventWireup</code> for the page, to ensure that this method is fired on the Page's OnLoad event:</p> <pre><code>&lt;%@ Page Language="C#" AutoEventWireup="true" %&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload