How to set opacity of exported map image?

Discussion created by shanksje on Oct 19, 2010
Latest reply on Oct 21, 2010 by shanksje

I'm loading an ArcGISDynamicMapServiceLayer into the map with an opacity of .8.  In the javascript viewer, the opacity looks correct.  When I export the map image using the following, the resulting image is 100% opaque.  Does anyone know how I can export the map image with the opacity settings preserved?


   var imageParams = new esri.layers.ImageParameters();
   //add the visible layers to the layerIds array
   imageParams.layerIds = [dynamicMapService.visibleLayers];
   imageParams.layerOption = esri.layers.ImageParameters.LAYER_OPTION_SHOW;
   imageParams.format = "png24";
   imageParams.height = 510;
   imageParams.width = 632;
   imageParams.dpi = 300;
   //get the map image URL
   dynamicMapService.exportMapImage(imageParams, mapImageURLCallback);