Export (0) Print
Expand All

CommonServiceSoap.GetDataSourceInfo Method

MapPoint Web Service is deprecated and will be retired November 18, 2011. Please go to http://www.microsoft.com/maps/mappoint.aspx for information about upgrading to Bing Maps.

Returns one or more data sources in an array of DataSource objects.

[Visual Basic]

Public Function GetDataSourceInfo (
 dataSourceNames As System.String() )
 As DataSource()

[C#] public DataSource[] GetDataSourceInfo (System.String[] dataSourceNames);

Parameters

dataSourceNames
Optional. An array of strings representing the DataSource.Name property of the data sources for which information is returned. The array can contain up to 500 items.

Remarks

  • The strings passed in the dataSourceNames parameter must match the DataSource.Name property exactly.

  • If the dataSourceNames parameter is null, the GetDataSourceInfo method returns a DataSource object for each DataSource object accessible by the caller.

  • The items in the DataSource array are returned in the same order as the items in the array passed in the dataSourceNames parameter.

Example


[Visual Basic]

'Get information about all available data sources
Dim commonService As New CommonServiceSoap()
Dim myDataSources() As DataSource
myDataSources = commonService.GetDataSourceInfo(Nothing)
Dim ds As DataSource
For Each ds In myDataSources
 Console.WriteLine(ds.Name)
Next

[C#] //This example assumes that the MapPoint Web Service namespace //has been imported //Get information about all available data sources CommonServiceSoap commonService = new CommonServiceSoap(); DataSource[] myDataSources; myDataSources = commonService.GetDataSourceInfo(null); foreach (DataSource ds in myDataSources) { Console.WriteLine(ds.Name); }

See Also

  CommonServiceSoap Class   |   DataSource.Name Property  

Show:
© 2014 Microsoft