Accepted answer

Here, I have fixed it for you. Here is a saved image:

Exported ImageFollowing changes have been done:

  1. Added a redraw event to your exportchart

    redraw: function () {
        $("#test_text").remove() ;
  2. Changed this line in afterSetExtremes



    $("#test_text").remove() ;

    Earlier one was not working as expected, so I had to change it.


Problem with disappearing text is related with id, when I removed it, label appears. But then I came across second issue, wrong y position. So i declare global variable, then when you call your function, set position of label, and use in chart exporting this variable. As a result label is exported correct.

Related Query

More Query from same tag