Location.DataSourceName Property

Location.DataSourceName Property

A string representing the name of the data source (DataSource.Name property) in which the specified Entity exists.


Public DataSourceName As System.String


[C#]

public System.String DataSourceName;

Example

[Visual Basic]

'Use the best map view to get a map of the found location
Dim findSpec As New FindSpecification()
findSpec.DataSourceName = "MapPoint.NA"
findSpec.InputPlace = "Seattle, WA"

Dim foundResults As FindResults
foundResults = findService.Find(findSpec)

Dim myViews(0) As ViewByHeightWidth
myViews(0) = foundResults.Results(0).FoundLocation.BestMapView.ByHeightWidth

Dim mapSpec As New MapSpecification()
mapSpec.DataSourceName = foundResults.Results(0).FoundLocation.DataSourceName
mapSpec.Views = myViews

Dim mapImages() As MapImage
mapImages = renderService.GetMap(mapSpec)



[C#]

//Use the best map view to get a map of the found location
FindSpecification findSpec  = new FindSpecification();
findSpec.DataSourceName = "MapPoint.NA";
findSpec.InputPlace = "Seattle, WA";

FindResults foundResults = findService.Find(findSpec);

ViewByHeightWidth[] myViews = new ViewByHeightWidth[1];
myViews[0] = foundResults.Results[0].FoundLocation.BestMapView.ByHeightWidth;

MapSpecification mapSpec = new MapSpecification();
mapSpec.DataSourceName = foundResults.Results[0].FoundLocation.DataSourceName;
mapSpec.Views = myViews;

MapImage[] mapImages;
mapImages = renderService.GetMap(mapSpec);


See Also

  Location Class   |   DataSource.Name Property   |   Location.Entity Property