jQuery UI Widgets Forums Chart saveAsPNG() with asmx

This topic contains 1 reply, has 1 voice, and was last updated by  toquehead 8 years, 5 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • saveAsPNG() with asmx #73444


    Can you please provide an example of an asmx implementation of the server method required by jqxChart(‘saveAsPNG’).

    The only thing I can find points me at the php example that ships with your pro version. That example is old: it is looking for POST variables format, filename, and content, when jqxChart is actually POSTing fname and content.

    But I need asmx anyway.


    saveAsPNG() with asmx #73445


    I managed to answer my own question. The stripped down asmx method is:

    public void DownloadContent(string fname, string content)
        var response = Context.Response;
        response.Charset = "UTF-8";
        response.ContentType = "application/octet-stream";
        response.AppendHeader("Content-Disposition", "attachment; filename=" + fname);
        byte[] bytes = Convert.FromBase64String(content);
        response.OutputStream.Write(bytes, 0, bytes.Length);
    • This reply was modified 8 years, 5 months ago by  toquehead.
Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.