WMS with Authentication

4801
3
07-09-2015 08:11 AM
MarvinKalani
New Contributor II

Hi,

I want to connect to a WMS Rest Service with a Basic Authentication but can not because I can not set the user credentials to access it.

When will this be possible? It seems that it was possible with WPF or Silverlight.

Greetings

Marvin

0 Kudos
3 Replies
JustinRodriguez
Occasional Contributor

Hello Marvin,

I hope you are doing well. WMS should be compatible with Basic Authentication. Here is an article that explains it pretty well:

ArcGIS Help (10.2, 10.2.1, and 10.2.2)

I hope that helps.

Thanks,

Justin

Esri Support

0 Kudos
MarvinKalani
New Contributor II

Hi Justin,

thanks for the fast answer, but your link has no article.

I am trying to connect a client via the SDK and C# by defining a WMS Layer programmatically. Like :

var uri = new Uri(uristring);

var wmsLayer = new WmsLayer(uri);

await wmsLayer.InitializeAsync();

Map.Layers.Add(wmsLayer);

The missing part is the part to define the credentials, but actually there is no :

wmsLayer.Usercredentials ... or wmsLayer.Username, wmsLayer.Password

best regards,

Marvin

0 Kudos
JesperBlom
New Contributor

Hi

I have the same problem. Can´t find any Credentials property in the Esri.ArcGISRuntime.Layers.WmsLayer class in the ArcGis API for .NET. I have used wmsLayer in the API for WPF and there it can be found in the class ESRI.ArcGIS.Client.Toolkit.DataSources.WmsLayer.

Regards

Jesper

0 Kudos