AnsweredAssumed Answered

Own coordinate system data (GK4) plus ArcGIS Basemap(WGS84)

Question asked by michaellodes on Jul 12, 2017

Dear community

 

I am working with ArcGIS API for JavaScript 4.4 und would like to create a map with a basemap in the background and my own features in foreground, which are in "Gauss-Krueger-4" coordinate systen (epsg: 31468).

 

Now to my questions: Can the ArcGIS Basemap be displayed just in WGS84-system? Or is it possible to display it also in GK4?

 

Do I have to transform my GK4 data into WGS84?

 

Below you can see my code. The map sets automatically WGS84 - obvisously immediately after displaying the basemap. Because of that, my GK4 coordinates can't be zoomed on. What am I doing wrong?

 

Thank you very much for looking up. Perhaps somebody knows the answer.

 

require([
  "esri/Map",
  "esri/views/MapView",
  "dojo/domReady!"
], function(Map, MapView) {
  var map = new Map({
    basemap: "streets"
  });

  var view = new MapView({
    container: "viewDiv",  // Reference to the DOM node that will contain the view
    map: map               // References the map object created in step 3
  });
 
 
      view.extent = new Extent({
      xmin: 4400000.0,
      ymin: 5335500.0,
      xmax: 4413500.0,
      ymax: 5346000.0,
   

      spatialReference: {
        wkid: 31468
      }
      });
   
    view.center = [4409051.287, 5341122.644];
    view.zoom = 14;



   



 
});

Outcomes