Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>You need to use AJAX for this. </p> <p>Here is the simplest possible example that will work but this is only to get you started. I oversimplified this for the demonstration purposes and it’s not really high quality.</p> <p><strong>Javascript code</strong></p> <p>Much better way to send data is through POST because GET is limited to around 2000 characters. </p> <p>Also, better way to format your data points would be through JSON. What I’ve shown below is not the best practice really ;)</p> <pre><code>&lt;script type="text/javascript"&gt; var xmlHttpRequest; function PostData() { //create XMLHttpRequest object xmlHttpRequest = (window.XMLHttpRequest) ? new XMLHttpRequest() : new ActiveXObject("Msxml2.XMLHTTP"); //If the browser doesn't support Ajax, exit now if (xmlHttpRequest == null) return; //Prepare your data points so they are in the format X1-Y1-X2-Y2-X3-Y3 pointData = "21-12-51-23-54-125-154-315-245-21" //Initiate the XMLHttpRequest object xmlHttpRequest.open("GET", "http://foo.com/Page.aspx?Points=" + pointData, true); //Send the Ajax request to the server with the GET data xmlHttpRequest.send(null); } &lt;/script&gt; C# code on the server protected void Page_Load(object sender, EventArgs e) { if (Request.QueryString["Points"] != null) { string rawData = Request.QueryString["Points"]; string []points = rawData.Split(new string[] { "-" }, StringSplitOptions.None); //continue parsing these to Ints and more... } } </code></pre> <p>Here are couple tutorials and resources that will help you to polish this up some more</p> <p><a href="http://www.codeproject.com/Articles/31155/Ajax-Tutorial-for-Beginners-Part-1" rel="nofollow noreferrer">http://www.codeproject.com/Articles/31155/Ajax-Tutorial-for-Beginners-Part-1</a></p> <p><a href="https://stackoverflow.com/questions/1102941/asp-net-ajax-examples-for-the-beginner">ASP .NET Ajax examples for the beginner</a></p>
 

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