" + dataletHeaderHtml + "
" var dataletHeader = "" + dataletHeaderHtml + "
" //debugger; dataletHeader = dataletHeader + mapLinks; if (hasManyPins) dataletHeader = dataletHeader + identRecNavHtml; var divName = "tc" + String(divN); var divNameHead = divName + "_header"; var divNameTab = divName + "_tab"; require(["dojo/dom-construct"], function(domConstruct){ //debugger; tcdn = dijit.byId(divName); if (tcdn!=null) { // Destroy a node byId: domConstruct.destroy(divName); //destroyrecursive? //dojo.destroy("tc1-prog2"); domConstruct.destroy(divNameHead); domConstruct.destroy(divNameTab); //tcdn.destroyRecursive(); } }); divN = divN + 1; divName = "tc" + String(divN); divNameHead = divName + "_header"; divNameTab = divName + "_tab"; require(["dojo/ready", "dijit/layout/TabContainer", "dijit/layout/ContentPane"], function(ready, TabContainer, ContentPane){ ready(function(){ chkDvi = document.getElementById(divName); if (chkDvi==null) { var newDivHolder = dojo.create("div", {}, "tc1-prog2"); newDivHolder.id = divName; var newDivHeader = dojo.create("div", {}, divName); newDivHeader.id = divNameHead; newDivHeader.innerHTML = dataletHeader; var newDivTab = dojo.create("div", {}, divName); newDivTab.id = divNameTab; } var tc = new TabContainer({ style: "height: 100%; width: 100%; border: solid 0px pink; overflow: hidden;", useMenu: false, useSlider: false, }, divNameTab); //debugger; var tabToSelect = null; var tab2Sel = null; var cp1 = new ContentPane({ title: "Parcel", content: "" }); tc.addChild(cp1); tabToSelect = cp1; var cp2 = new ContentPane({ title: "Sales", content: "" }); tc.addChild(cp2); if (curSelectedTab==null && tabToSelect==null) tabToSelect = cp2; else if (curSelectedTab!=null && curSelectedTab.title==cp2.title) tabToSelect = cp2; else tab2Sel = cp2; tc.selectChild(tab2Sel); tc.startup(); tc.selectChild(tabToSelect); tc.watch("selectedChildWidget", function(name, oval, nval){ //debugger; //console.log("selected child changed from ", oval, " to ", nval); curSelectedTab = nval; if (nval.title=="Pictometry") refeshPictTab(); }); currentTabControl = tc; //cp = dijit.byId("tc1-prog").domNode; //cp = document.getElementById("tc1-prog"); finalHtmlContent = newDivHolder; }); }); return finalHtmlContent; }function refeshPictTab() { //alert('"Pictometry"'); picIFrame = document.getElementById('picFrame'); //tail='&r+'+Math.round(Math.random*10000); picIFrame.src = picIFrame.src;// + tail;}var lat;var lon;function SetLatLongForLinks(latitude,longitude) { //debugger; lat = latitude; lon = longitude;}function QueryAGSParcelMapServiceForLatLong(gisPins, geometry) { //debugger; if (pictometryParcelServiceQueryUrl.length<1 || pictometryParcelServiceQueryUrl.indexOf("maps.akanda.com")>-1) return; var queryTask = new esri.tasks.QueryTask(pictometryParcelServiceQueryUrl); //build query filter var query = new esri.tasks.Query(); query.returnGeometry = true; query.outFields = [targetfieldname]; if (geometry != null) query.geometry = geometry; if (gisPins.length>0) { gisPinsWQuotes = "'" + gisPins.replace(/,/gi,"','") + "'"; var dirty = (new Date()).getTime(); //query.where = targetfieldname + " in (" + gisPinsWQuotes + ")"; if (makeQueryWhereDirty) query.where = targetfieldname + " in (" + gisPinsWQuotes + ") OR " + targetfieldname + "='" + dirty + "'"; else query.where = targetfieldname + " in (" + gisPinsWQuotes + ")"; } dojo.connect(queryTask, "onError", function(error) { //debugger; er = error; showProgressImage(false); if (error.code==400 && error.details.length>0) { if (error.details[0]=="Unable to perform query. Please check your parameters.") { if (geometry!=null) mesg = "Unable to perform query. You may have exceeded the maximum of " + maxMappedParcels + " parcels or you have drawn illegal geometry . Try not to select so many parcels or draw overly complex polygons that crossover or create holes. Please try again."; else mesg = "Unable to perform query. You may have exceeded the maximum of " + maxMappedParcels + " parcels. Please try again."; } } else mesg = "Error executing Query. Error: " + error.code + ": " + error.details[0] + " Please try again."; ShowMessage(mesg,true,true); return; }); //Can listen for onComplete event to process results or can use the callback option in the queryTask.execute method. dojo.connect(queryTask, "onComplete", function(featureSet) { //debugger; var polysExtent = null; if (featureSet!=null && featureSet.features!=null) featureCount = featureSet.features.length; if (featureCount==0) { mesg = "Could not find parcel from map service. No geographic information exists for this parcel."; ShowMessage(mesg,true,true); return; } else if (featureCount>=maxQueryFeatures) { mesg = "You have exceeded the maximum number of " + maxQueryFeatures + " selected parcels. Please try again using a smaller selection."; ShowMessage(mesg,true,true); return; } else { for (var i = 0; i < featureCount; i++) { //Get the current feature from the featureSet. //Feature is a graphic var graphic = featureSet.features[i]; if (graphic!=null) { if (polysExtent==null) polysExtent = graphic.geometry.getExtent(); else polysExtent.union(graphic.geometry.getExtent()); //this calculates centerpoint of multiple polys based on the centerpoint of the overall combined extent centerpoint point = polysExtent.getCenter(); if (point!=null && point.x!=null) { latitude = point.y; longitude = point.x; newLatLong = true; } } } if (newLatLong) SetLatLongForLinks(latitude,longitude); else SetLatLongForLinks(null,null); showProgressImage(false); } });queryTask.execute(query);showProgressImage(true);}//var largePhotoShowing = false;var photoTabLarge = document.getElementById('PhotoTabLarge');var skechTabLarge = document.getElementById('SketchTabLarge');function hideLargeSketch() { $("#SketchTabLarge").slideUp(150);}function showLargeSketch(imgEl) { sImgHtml = ""; sImgHtml = sImgHtml + ""; skechTabLarge.innerHTML = sImgHtml; skechTabLarge.style.left = map.infoWindow.coords.x+'px'; skechTabLarge.style.top = map.infoWindow.coords.y+'px'; $("#SketchTabLarge").slideDown(150); }function hideLargePhoto() { $("#PhotoTabLarge").slideUp(150); //$("#PhotoTabLarge").hide();}function showLargePhoto(imgEl) { //debugger; //var pt = map.toMap(screenPoint); //map.toMap(map.infoWindow.coords.x),map.toMap(map.infoWindow.coords.y) //var pt = new esri.geometry.Point(,map.spatialReference) //var sms = new esri.symbol.SimpleMarkerSymbol().setStyle(esri.symbol.SimpleMarkerSymbol.STYLE_SQUARE).setColor(new dojo.Color([255,0,0,0.5])); //var attr = {"XCoord":map.infoWindow.coords.x,"YCoord":map.infoWindow.coords.y,"Photo":"123"}; //var infoTemplate = new esri.InfoTemplate("Vernal Pool Locations","Latitude: ${YCoord}Longitude: ${XCoord}
Plant Name:${Plant}"); //var graphic = new esri.Graphic(pt,sms,attr,infoTemplate); //map.graphics.add(graphic); //largePhotoShowing = true; sImgHtml = ""; sImgHtml = sImgHtml + ""; photoTabLarge.innerHTML = sImgHtml; photoTabLarge.style.left = map.infoWindow.coords.x+'px'; photoTabLarge.style.top = map.infoWindow.coords.y+'px'; //$("#PhotoTabLarge").show(); $("#PhotoTabLarge").slideDown(150); }//function followMouseDrag(e) {// //debugger;// if (largePhotoShowing) {// photoTabLarge.style.left = map.infoWindow.coords.x;// photoTabLarge.style.top = map.infoWindow.coords.y;// showMessage("X:" + map.infoWindow.coords.x + " Y:" + map.infoWindow.coords.y);// }// //}function GetDataletHtml(name, parId, taxYear, jur, ownerSeq, active){var pars = SoapBuildInputParam("name", name);pars += SoapBuildInputParam("parId", parId);pars += SoapBuildInputParam("taxYear", taxYear);pars += SoapBuildInputParam("jur", jur);pars += SoapBuildInputParam("ownerSeq", ownerSeq);pars += SoapBuildInputParam("active", "Y");var html = SoapInvokeService("../Datalets/Services/DataletServices.asmx", "MakeSimpleDatalet", pars, false); if (html.length<1) return "No Data"; return html;}var winPopupWidth = 450;var winPopupHeight = 350;var winLinkWidth = window.screen.availWidth - 20;var winLinkHeight = window.screen.availHeight -20;var winLinkLeft = 10;var winLinkTop = 10;//var t = screen.height / 2;//var l = screen.height / 2;function LaunchPRMDatalet() { var url = "https://publicaccess.co.olmsted.mn.us/" + dataletLink; window.open(url, '', "_fullscreen=yes, titlebar=yes, location=no, toolbar=yes, status=no, menubar=yes, resizable=yes, scrollbars=yes");}function GetDataAndShowPictometry(sParid,sJur,sTaxyr) { strPin = sJur + ":" + sParid + ":" + sTaxyr; if (linksAreExternal) { if (lat==null || lon==null) { mesg = "Cannot not retrieve coordinates for current parcel."; ShowMessage(mesg,true,true); return; } url = POLLinkUrl + "&lat=" + lat + "&lon=" + lon; //"&lat=44.74275&lon=-93.20669"; sW = winLinkWidth; sH = winLinkHeight; l = winLinkLeft; t = winLinkTop; } else { sW = winPopupWidth; sH = winPopupHeight; l = window.event.clientX; t = window.event.clientY; url = "https://publicaccess.co.olmsted.mn.us/pictometry/PictometryIPAIFrame.aspx?pin=" + strPin + "&fullWindow=true&w=" + sW + "px&h=" + sH + "px"; } window.open(url, 'Pictometry', "_fullscreen=yes, top=" + t + ", left=" + l + ", width=" + sW + ", height=" + sH + ", titlebar=no, location=no, toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes");}function GetDataAndShowMap(sParid,sJur,sTaxyr) { strPin = sJur + ":" + sParid + ":" + sTaxyr; sW = winPopupWidth; sH = winPopupHeight; l = window.event.clientX; t = window.event.clientY; url = "https://publicaccess.co.olmsted.mn.us/Maps/MapAdv.aspx?pageType=Advanced&fullmap=true&pins=" + strPin + "&parid=" + sParid + "&jur=" + sJur + "&taxyr=" + sTaxyr + "&fullWindow=true"; //&w=" + sW + "px&h=" + sH + "px"; //http://localhost/iasworld/Maps/SimpleMap.aspx?pageType=Photo&plotParcelsAsPolys=true&jur=000&parid=001001 J00003 window.open(url, 'Map', 'top=0, left=0, location=no, scrollbars=no, menubar=no, resizable=yes, height=' + screenHeight + ', width=' + screenWidth); //window.open(url, 'Map', "_fullscreen=yes, top=" + t + ", left=" + l + ", width=" + sW + ", height=" + sH + ", titlebar=no, location=no, toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes"); //ArcGISMaps/ArcGISMap.aspx?pageType=iAnalyze2Overview&pins=000:L0159G%20A00021:2003&jur=000&taxyr=2003} function GetDataAndShowGoogleMap(sParid,sJur,sTaxyr) { strPin = sJur + ":" + sParid + ":" + sTaxyr; if (linksAreExternal) { if (lat==null || lon==null) { mesg = "Cannot not retrieve coordinates for current parcel."; ShowMessage(mesg,true,true); return; } sW = winLinkWidth; sH = winLinkHeight; l = winLinkLeft; t = winLinkTop; //url = "http://maps.google.ca/maps?daddr=" + lat + "," + lon + "&hl=en&ll=" + lat + "," + lon + "&spn=0.001737,0.003259&sll=" + lat + "," + lon + "&sspn=0.006947,0.013036&vpsrc=0&mra=mift&mrsp=1&sz=17&t=h&z=19&iwloc=ddw1";//&vpsrc=6&mra=mift&mrsp=1&sz=17&t=m&z=19&iwloc=ddw1"; url = "http://maps.google.ca/maps?q=" + lat + "," + lon + "&hl=en&ll=" + lat + "," + lon + "&spn=0.001084,0.001608&sll=" + lat + "," + lon + "&sspn=0.006947,0.013036&vpsrc=6&mra=mift&mrsp=1&sz=17&t=h&z=20&iwloc=ddw1"; } else { sW = winPopupWidth; sH = winPopupHeight; l = window.event.clientX; t = window.event.clientY; url = "https://publicaccess.co.olmsted.mn.us/iAnalyzeV2/GoogleMap.aspx?googleMapType=Basic&parids=" + sParid + "&jur=" + sJur + "&taxyr=" + sTaxyr + "&fullWindow=true&w=" + sW + "px&h=" + sH + "px"; } window.open(url, 'GoogleMap', "_fullscreen=yes, top=" + t + ", left=" + l + ", width=" + sW + ", height=" + sH + ", titlebar=no, location=no, toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes"); //iAnalyzeV2/GoogleMap.aspx?googleMapType=Basic&parids=L0159G%20A00021&jur=000&taxyr=2003}function GetDataAndShowVEMap(sParid,sJur,sTaxyr) { strPin = sJur + ":" + sParid + ":" + sTaxyr; if (linksAreExternal) { if (lat==null || lon==null) { mesg = "Cannot not retrieve coordinates for current parcel."; ShowMessage(mesg,true,true); return; } sW = winLinkWidth; sH = winLinkHeight; l = winLinkLeft; t = winLinkTop; //url = "http://www.bing.com/maps/?v=2&cp=" + lat + "~" + lon + "&lvl=19&dir=0&sty=r&rtp=adr.~pos." + lat + "_" + lon + "____a_&mode=D&rtop=0~0~0~&form=LMLTCC"; url = "http://www.bing.com/maps/?v=2&cp=" + lat + "~" + lon + "&lvl=20&dir=0&sty=h&rtp=adr.~pos." + lat + "_" + lon + "____a_&mode=D&rtop=0~0~0~&form=LMLTCC"; } else { sW = winPopupWidth; sH = winPopupHeight; l = window.event.clientX; t = window.event.clientY; url = "https://publicaccess.co.olmsted.mn.us/iAnalyzeV2/VirtualEarth.aspx?pin=" + sParid + "&jur=" + sJur + "&taxyr=" + sTaxyr + "&fullWindow=true&w=" + sW + "px&h=" + sH + "px"; } window.open(url, 'VEMap', "_fullscreen=yes, top=" + t + ", left=" + l + ", width=" + sW + ", height=" + sH + ", titlebar=no, location=no, toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes"); //iAnalyzeV2/VirtualEarth.aspx?pin=L0159G%20A00021&jur=000&taxyr=2003}function GetDataKml(sParid,sJur,sTaxyr) { var url = 'GoogleEarth.aspx?pin=' + sParid + "&jur=" + sJur + "&taxyr=" + sTaxyr; url = url + "&lat=" + lat + "&lon=" + lon; window.open(url);}dojo.addOnLoad(init); //add error handler to display any error messages//function errorHandler(error) {// alert(error.message);//}var numExports = 0;var numExported = 0;var layerOpacities = [];var layerTileUrls = [];var tileUrls = [];var dynamicUrls = [];var features = [];function exportMap() { //debugger; layerOpacities = [];layerTileUrls = [];tileUrls = [];dynamicUrls = [];features = [];graphics = ""; showProgressImage(true); lo=0;for (var j = 0, jl = map.layerIds.length; j < jl; j++) { var layer = map.getLayer(map.layerIds[j]); if (layer.visible) { GetLayerInfoForMerge(layer,lo); lo=lo+1; }} graphics = GetScreenGraphic(); //alert('tileUrls: ' + tileUrls); //alert('dynamicUrls: ' + dynamicUrls); //alert('features: ' + features); //alert('graphics: ' + graphics); //debugger; CombineImageService.CombineImages(dojo.toJson(tileUrls), dojo.toJson(dynamicUrls), dojo.toJson(features), graphics, mapCtrlHeight, mapCtrlWidth, imageFormat, OnComplete2, OnTimeOut2, OnError2); //window.open("StreamAGSJSMapImage.aspx?tileUrls=" + dojo.toJson(tileUrls) + "&dynamicUrls=" + dojo.toJson(dynamicUrls) + "&features=" + dojo.toJson(features) + "&graphics=" + graphics);}function OnComplete2(arg) { showProgressImage(false); document.getElementById("isPrintReady").value = "yesprintready"; if (bPorE=="download") arg = arg + "&forceDownload=true"; document.getElementById("printUrl").value = arg; //extCom = window.external; //debugger; window.open(arg); //window.location = arg;}function OnTimeOut2(arg) { //alert("TimeOut: " + arg); mesg = "TimeOut error occurred:" + arg + ". This error could be due to the Map Server timing out or not supporting the request made. ie.(map server may not support images of this size, check your server settings)."; ShowMessage(mesg,true,true);}function OnError2(arg) { //alert("Error: " + arg); mesg = "Error occurred: " + arg; ShowMessage(mesg,true,true);}function GetLayerInfoForMerge(layer,layerOrder) { var extent = this.map.extent; var height = this.map.height; var width = this.map.width; if (false) { //layer instanceof esri.layers.ArcGISTiledMapServiceLayer) { var candidateTileInfo = esri.TileUtils.getCandidateTileInfo(this.map, layer.tileInfo, extent); var layerTileUrls = []; var tileXOffset = Math.ceil(width / layer.tileInfo.width); var tileYOffset = Math.ceil(height / layer.tileInfo.height); // the internal function name prefix change to __ in v1.5 var delta = this.map._visibleDelta ? this.map._visibleDelta : this.map.__visibleDelta; for ( var x = 0; x <= tileXOffset; x++) { for ( var y = 0; y <= tileYOffset; y++) { var tileUrl = layer.url + "/tile/" + this.map.getLevel() + "/" + (candidateTileInfo.tile.coords.row + y) + "/" + (candidateTileInfo.tile.coords.col + x); layerTileUrls.push( { "url" : ConvertUrlToAbsolute(tileUrl), "row" : candidateTileInfo.tile.coords.row + y, "col" : candidateTileInfo.tile.coords.col + x }); } } tileUrls.push( { "layerOrder" : layerOrder, "tiles" : layerTileUrls, "transparency" : layer.opacity, "clipOptions" : { "offsetX" : candidateTileInfo.tile.offsets.x - delta.x, "offsetY" : candidateTileInfo.tile.offsets.y - delta.y, "width" : width, "height" : height } }); } else if (layer instanceof esri.layers.ArcGISTiledMapServiceLayer || layer instanceof esri.layers.ArcGISDynamicMapServiceLayer || layer instanceof esri.layers.ArcGISImageServiceLayer) { var dynamicUrl = layer.url + "/export?bbox=" + extent.xmin + "," + extent.ymin + "," + extent.xmax + "," + extent.ymax + "&size=" + width + "," + height + "&transparent=true&format=png24&f=image"; if (layer instanceof esri.layers.ArcGISImageServiceLayer) { dynamicUrl = dynamicUrl.replace("export?", "exportImage?"); } else { // handle layer visibility... if (layer.visibleLayers.length > 0) { dynamicUrl += "&layers=show:"; } for ( var i = 0; i < layer.visibleLayers.length; i++) { dynamicUrl += layer.visibleLayers[i]; dynamicUrl += i + 1 < layer.visibleLayers.length ? "," : ""; } } dynamicUrls.push( { "layerOrder" : layerOrder, "url" : ConvertUrlToAbsolute(dynamicUrl), "width" : this.map.width, "height" : this.map.height, "extent" : this.map.extent, "transparency" : layer.opacity }); } else if (layer instanceof esri.layers.GraphicsLayer) { var geometries = []; var colors = []; var graphics = layer.graphics; for ( var i = 0; i < graphics.length; i++) { var geometry = esri.geometry.toScreenGeometry( extent, width, height, graphics[i].geometry); if (geometry instanceof esri.geometry.Polygon) { geometries.push({ "geometryType" : "esriGeometryPolygon", "rings" : geometry.rings, "symbol" : graphics[i].symbol.toJson() }); } else if (geometry instanceof esri.geometry.Point) { geometries.push({ "geometryType" : "esriGeometryPoint", "x" : geometry.x, "y" : geometry.y, "symbol" : graphics[i].symbol.toJson() }); } else if (geometry instanceof esri.geometry.Polyline) { geometries.push({ "geometryType" : "esriGeometryPolyline", "paths" : geometry.paths, "symbol" : graphics[i].symbol.toJson() }); } else { console.log("Unknown geometry: ", geometry); } colors.push( graphics[i].symbol.color); } features.push({ "layerOrder" : layerOrder, "geometries" : geometries, "colors" : colors, "transparency" : 0.5, "width" : width, "height" : height }); } }function exportMap3() { var extent = this.map.extent; var height = this.map.height; var width = this.map.width; showProgressImage(true); numExports = 0; numExported = 0; var imgParams = new esri.layers.ImageParameters(); imgParams.bbox = extent; imgParams.width = width; imgParams.height = height; imgParams.transparent = false; //base map not transparent var imageList = ""; var tileList = ""; for (var j = 0, jl = map.layerIds.length; j < jl; j++) { var layer = map.getLayer(map.layerIds[j]); if (layer.visible) { if (numExports>1) imgParams.transparent = true; //layer.setImageFormat("png24"); if (layer.declaredClass=="esri.layers.ArcGISTiledMapServiceLayer") { //var layer2 = new esri.layers.ArcGISDynamicMapServiceLayer(layer.url, { id: "temp"+j, visible: true }); //layer2.setImageFormat("png24"); //layer2.setOpacity(layer.opacity); //layer = layer2; var candidateTileInfo = esri.TileUtils.getCandidateTileInfo(map, layer.tileInfo, extent); var layerTileUrls = []; var tileXOffset = Math.ceil(width / layer.tileInfo.width); var tileYOffset = Math.ceil(height / layer.tileInfo.height); // the internal function name prefix change to __ in v1.5 var delta = this.map._visibleDelta ? this.map._visibleDelta : this.map.__visibleDelta; for ( var x = 0; x <= tileXOffset; x++) { for ( var y = 0; y <= tileYOffset; y++) { var tileUrl = layer.url + "/tile/" + this.map.getLevel() + "/" + (candidateTileInfo.tile.coords.row + y) + "/" + (candidateTileInfo.tile.coords.col + x); layerTileUrls.push( { "url" : ConvertUrlToAbsolute(tileUrl), "row" : candidateTileInfo.tile.coords.row + y, "col" : candidateTileInfo.tile.coords.col + x }); } } tileUrls.push( { "tiles" : layerTileUrls, "transparency" : layer.opacity, "clipOptions" : { "offsetX" : candidateTileInfo.tile.offsets.x - delta.x, "offsetY" : candidateTileInfo.tile.offsets.y - delta.y, "width" : width, "height" : height } }); } else { layer.setImageFormat("png24"); layerOpacities.push(layer.opacity); numExports = numExports + 1; layer.exportMapImage(imgParams, function (mapImage) { //debugger; if (imageList.length>0) imageList += "$"; //if (imageList.length>0) imageList = "$" + imageList; imageList += mapImage.href + ";" + layerOpacities[numExported]; //imageList = mapImage.href + ";" + layerOpacities[numExported] + imageList numExported = numExported + 1; if (numExported==numExports) { //Get screen graphics imageList += "|" + GetScreenGraphic(); //ajax call the web service to blend images //alert(imageList); //alert(tileUrls); CombineImageService.CombineImageList(imageList, tileUrls, OnComplete, OnTimeOut, OnError); } }); } }}}function ConvertUrlToAbsolute(url) { if (url) { if (url.indexOf("http") != 0) { var escapeHTML = function (s) { return s.split('&').join('&').split('<').join('<').split('"').join('"'); }; var el= document.createElement('div'); el.innerHTML= 'x'; url = el.childNodes[0].href; } } return url;}function exportMap2() { showProgressImage(true); numExports = 0; numExported = 0; var imgParams = new esri.layers.ImageParameters(); imgParams.bbox = map.extent; imgParams.width = map.width; imgParams.height = map.height; imgParams.transparent = false; //base map not transparent var imageList = ""; for (var j = 0, jl = map.layerIds.length; j < jl; j++) { var layer = map.getLayer(map.layerIds[j]); if (layer.visible) { if (numExports>1) imgParams.transparent = true; //layer.setImageFormat("png24"); if (layer.declaredClass=="esri.layers.ArcGISTiledMapServiceLayer") { var layer2 = new esri.layers.ArcGISDynamicMapServiceLayer(layer.url, { id: "temp"+j, visible: true }); layer2.setImageFormat("png24"); layer2.setOpacity(layer.opacity); layer = layer2; } else layer.setImageFormat("png24"); layerOpacities.push(layer.opacity); numExports = numExports + 1; layer.exportMapImage(imgParams, function (mapImage) { //debugger; if (imageList.length>0) imageList += "$"; //if (imageList.length>0) imageList = "$" + imageList; imageList += mapImage.href + ";" + layerOpacities[numExported]; //imageList = mapImage.href + ";" + layerOpacities[numExported] + imageList numExported = numExported + 1; if (numExported==numExports) { //Get screen graphics imageList += "|" + GetScreenGraphic(); //ajax call the web service to blend images //alert(imageList); CombineImageService.CombineImageList(imageList, OnComplete, OnTimeOut, OnError); //SimpleService.BlendImageList(imageList, OnComplete, OnTimeOut, OnError); } }); } }}function PushGraphicsFromLayersToMapGraphicLayer() { for (var l=0; l