Html5 Canvas Got Refresh After Postback In Asp.net
I am using HTML5 canvas tag and Jquery plugin for free handwriting in my asp.net application. http://www.websanova.com/plugins/paint/html5#websanova I am facing one problem. When M
Solution 1:
Naturally round-trip (postback) will erase the drawing. In order to send & save the dataUri
you have to write WebMethod
or WCF service
and request it jQuery.ajax()
.
Solution 2:
The most easy way to solve this is to make an ajax post back, and stay on page.
The second difficult solution is to re-paint your canvas with the image that you have from the previous post back.
Solution 3:
You can try put this save-button inside UpdatePanel
Solution 4:
HI you can put your form which is runat server in an iframe and do the uploading stuff there. After successful upload use $('#Id',window.parent.document) to access the parent html from the iframe and set the image. The post back will happen in iframe and your canvas will not get affected.
Post a Comment for "Html5 Canvas Got Refresh After Postback In Asp.net"