Use applet save button or there javascript commands
  • Save...
  • See image (after save)...

  • In this sample you can see the use of the "Save" option by using the ASP component acxImage (it is possible to replace it by the JSP component jspImage for non IIS servers).
    WARNING ! : to save the image with this page you must install acxImage in your site and use aDraw applet in your http server.

Sample ASP code to build image (save) :
	Dim str, w, h
	str = Request.Form("data")
	wa  = Request.Form("w") 
	ha  = Request.Form("h") 

	sScriptDir = Request.ServerVariables("SCRIPT_NAME")
	sScriptDir = StrReverse(sScriptDir)
	sScriptDir = Mid(sScriptDir, InStr(1, sScriptDir, "/"))
	sScriptDir = StrReverse(sScriptDir)
	' Set the virtual Directory
  	sPath = Server.MapPath(sScriptDir) & "\"

	Set h = Server.CreateObject("javaside.Rbl.acxImage") 

	h.init wa, ha
	h.readData str

	' You can add an external text (or other draw command) 
	h.setColor 0
	h.drawString "genere le " & now, 8, 12

	' build image (with data get in aDraw applet)
	' get image 0 => GIF   1 => PNG
	img = h.getArray(0)

	h.saveAs( sPath & "cook2.gif")

	Set h = nothing