Constructor Map
Map()
Initializes a new instance of the Map class.
Declaration
public Map()
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.3 - 100.15 |
| .NET 6.0 | 100.13 - 100.15 |
| .NET 6.0 Windows | 100.13 - 100.15 |
| .NET Framework | 100.0 - 100.15 |
| .NET 5 | 100.10 - 100.12 |
| .NET Core 3.1 | 100.7 - 100.12 |
| Xamarin.Android | 100.0 - 100.15 |
| Xamarin.iOS | 100.0 - 100.15 |
| UWP | 100.0 - 100.15 |
Relevant samples
Map(Basemap)
Declaration
public Map(Basemap basemap)
Parameters
| Type | Name | Description |
|---|---|---|
| Basemap | basemap | The basemap for the map. |
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.3 - 100.15 |
| .NET 6.0 | 100.13 - 100.15 |
| .NET 6.0 Windows | 100.13 - 100.15 |
| .NET Framework | 100.0 - 100.15 |
| .NET 5 | 100.10 - 100.12 |
| .NET Core 3.1 | 100.7 - 100.12 |
| Xamarin.Android | 100.0 - 100.15 |
| Xamarin.iOS | 100.0 - 100.15 |
| UWP | 100.0 - 100.15 |
Relevant samples
Map(BasemapStyle)
Initializes a new instance of the Map class with a BasemapStyle.
Declaration
public Map(BasemapStyle basemapStyle)
Parameters
| Type | Name | Description |
|---|---|---|
| BasemapStyle | basemapStyle | Style of the basemap. |
Remarks
These basemaps are secured and access requires either an ApiKey or a named user.
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.10 - 100.15 |
| .NET 6.0 | 100.13 - 100.15 |
| .NET 6.0 Windows | 100.13 - 100.15 |
| .NET Framework | 100.10 - 100.15 |
| .NET 5 | 100.10 - 100.12 |
| .NET Core 3.1 | 100.10 - 100.12 |
| Xamarin.Android | 100.10 - 100.15 |
| Xamarin.iOS | 100.10 - 100.15 |
| UWP | 100.10 - 100.15 |
Map(BasemapType, Double, Double, Int32)
Declaration
public Map(BasemapType basemapType, double latitude, double longitude, int levelOfDetail)
Parameters
| Type | Name | Description |
|---|---|---|
| BasemapType | basemapType | Type of the basemap. |
| System.Double | latitude | The latitude for the initial viewpoint. |
| System.Double | longitude | The longitude for the initial viewpoint. |
| System.Int32 | levelOfDetail | The level of detail (converted to scale) for the initial viewpoint. 0 is the most zoomed out. |
Remarks
The map will be created with a basemap set, a spatial reference in WGS84, and the initial viewpoint set. In order to take advantage of geographically load-balanced services and monitor usage with API keys or named users, use BasemapStyle.
See Also
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.3 - 100.13 |
| .NET 6.0 | 100.13 |
| .NET 6.0 Windows | 100.13 |
| .NET Framework | 100.0 - 100.13 |
| .NET 5 | 100.10 - 100.12 |
| .NET Core 3.1 | 100.7 - 100.12 |
| Xamarin.Android | 100.0 - 100.13 |
| Xamarin.iOS | 100.0 - 100.13 |
| UWP | 100.0 - 100.15 |
Relevant samples
Map(Uri)
Initializes a new instance of the Map class with a Uri to a web map.
Declaration
public Map(Uri uri)
Parameters
| Type | Name | Description |
|---|---|---|
| Uri | uri | Uri of a webmap on ArcGIS Online or ArcGIS Enterprise portal. A PortalItem will be created to reference the webmap and accessible through Item. |
Remarks
If the specified Uri is a portal item URL CreateAsync(Uri, Credential),
the underlying PortalItem will be created and accessible through Item.
The uri may be a direct Uri to web map JSON content or the Uri of a portal item.
The supported URL formats are:
- The URL of a webmap opened in the portal's map viewer web application (classic or new). Example: https://www.arcgis.com/home/webmap/viewer.html?webmap=8bf7167d20924cbf8e25e7b11c7c502c or https://www.arcgis.com/apps/mapviewer/index.html?webmap=8bf7167d20924cbf8e25e7b11c7c502c
- The URL of the webmap item details web page. Example: https://www.arcgis.com/home/item.html?id=c6a2c53ead68432586cc9ac9ec366055
- The REST Sharing API URL of the webmap item (with or without the query parameter f=json). Example: https://www.arcgis.com/sharing/rest/content/items/c6a2c53ead68432586cc9ac9ec366055?f=json
- The REST Sharing API URL of the webmap item data. Example: https://www.arcgis.com/sharing/rest/content/items/c6a2c53ead68432586cc9ac9ec366055/data
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| UWP | 100.15 |
Map(Item)
Initializes a new instance of the Map class with an ArcGIS Item.
Declaration
public Map(Item item)
Parameters
| Type | Name | Description |
|---|---|---|
| Item | item | The webmap item. Only PortalItem are supported. |
Remarks
The specified item must be of type WebMap or the Map will fail to load
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.3 - 100.15 |
| .NET 6.0 | 100.13 - 100.15 |
| .NET 6.0 Windows | 100.13 - 100.15 |
| .NET Framework | 100.0 - 100.15 |
| .NET 5 | 100.10 - 100.12 |
| .NET Core 3.1 | 100.7 - 100.12 |
| Xamarin.Android | 100.0 - 100.15 |
| Xamarin.iOS | 100.0 - 100.15 |
| UWP | 100.0 - 100.15 |
Relevant samples
Map(SpatialReference)
Initializes a new instance of the Map class with a specified spatial reference.
Declaration
public Map(SpatialReference spatialReference)
Parameters
| Type | Name | Description |
|---|---|---|
| SpatialReference | spatialReference | The spatial reference to use on the map. |
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.3 - 100.15 |
| .NET 6.0 | 100.13 - 100.15 |
| .NET 6.0 Windows | 100.13 - 100.15 |
| .NET Framework | 100.0 - 100.15 |
| .NET 5 | 100.10 - 100.12 |
| .NET Core 3.1 | 100.7 - 100.12 |
| Xamarin.Android | 100.0 - 100.15 |
| Xamarin.iOS | 100.0 - 100.15 |
| UWP | 100.0 - 100.15 |