AnsweredAssumed Answered

Switch basemap WKID to 3440

Question asked by on Oct 4, 2016
Latest reply on Oct 4, 2016 by thejus.kambi


I am a web application developer new to ESRI javascript API. My company wants to use ESRI Map service to plot their data in Map. I have achieved all my requirement with ESRI javascript API except setting custom SpatialReference.  because my company is using a specific system: PSD93 so I want to set a custom WKID: 3440 with the basemap:"topo" to complete the requirement.



Thanks in advance


please see my below code:

var map, toolbar, symbol, geomTask, linesymbol, customExtentAndSR, sr, webutil; require(["esri/map","esri/toolbars/draw","esri/dijit/BasemapGallery","esri/graphic","esri/symbols/SimpleMarkerSymbol","esri/symbols/SimpleLineSymbol","esri/symbols/SimpleFillSymbol","esri/symbols/CartographicLineSymbol","esri/symbols/PictureMarkerSymbol","dojo/parser""dijit/registry","dijit/layout/BorderContainer""dijit/layout/ContentPane","dijit/form/Button""dijit/WidgetSet""dojo/domReady!""esri/SpatialReference""esri/geometry/Extent"], function ( Map, Draw, BasemapGallery, Graphic, SimpleMarkerSymbol, SimpleLineSymbol, SimpleFillSymbol, CartographicLineSymbol, PictureMarkerSymbol, parser, registry, SpatialReference, webMercatorUtils, Extent ) {     parser.parse();

 bounds = new esri.geometry.Extent({             "xmin": 180203.8880,             "ymin": 1859530.0038,             "xmax": 809128.4715,             "ymax": 2923231.7211,             "spatialReference": { "wkid": 3440 }         });


var renewPoint = new esri.geometry.Point(defaultLong, defaultLat, new esri.SpatialReference({ "wkid": 3440 }));         
map = new Map("map", {             basemap: "topo",             center: [defaultLong, defaultLat], zoom: defaultZoom, force3DTransforms: true        });