c# imageObj.save method not working properly?
Tamas Szekeres
szekerest at GMAIL.COM
Tue Oct 24 14:46:03 PDT 2006
Hi Paolo,
You might have to explicitly set the mapObj.path property after loading the map.
Best Regards,
Tamas
2006/10/24, Paolo Corti <pcorti at gmail.com>:
> Hello all Looks like the imageObj.save(filename) metod doesn't work
> properly I correctly set IMAGEPATH and IMAGEURL in mapfile: WEB IMAGEPATH
> "C:/Inetpub/wwwroot/output" IMAGEURL "http://localhost/output" END If I try
> to write the image to disk with imageObj.save(filename) the image is not
> saved in the IMAGEPATH location, but in the mapfile's folder. For example if
> I save the image: imageObj.save("test.jpg") The image test.jpg is not
> written under IMAGEPATH("C:/Inetpub/wwwroot/output") but in
> the mapfile folder (another folder). The workaround is to give the fullname
> of image, like here: public override String GetURLMap() { //refresh map
> imageObj image = map.draw(); //be sure to have set Web parameters in mapfile
> (IMAGEPATH, IMAGEURL) //return URLMap String ImageName =
> DateTime.Now.Second.ToString() +
> DateTime.Now.Millisecond.ToString() + "." +
> map.outputformat.extension; image.save(image.imagepath + "\\" + ImageName,
> map); //image.save(ImageName, map); return image.imageurl + "/" + ImageName;
> } but I am wondering how no one still pointed out this bug, maybe I
> configured something wrong in map file. Any help appreciated Paolo Corti
> http://www.paolocorti.net
> ________________________________
> View this message in context: c# imageObj.save method not working properly?
> Sent from the Mapserver - User mailing list archive at Nabble.com.
>
More information about the MapServer-users
mailing list