GetDemographics method
Creates a data set of demographics for a specified country or for worldwide data. Returns a DataSet object.
Note Countries for which demographic data is available vary between Microsoft MapPoint with European maps and MapPoint with North American maps. For more information, see the Country parameter description.
Applies to
Collections: DataSets
Syntax
object.GetDemographics(Country)
Parameters
Part | Description | ||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
object | Required. An expression that returns a DataSets collection. | ||||||||||||||||||||||||||||||||||||
Country | Required GeoCountry. The country for which demographics are added. Default is geoCountryDefault. The following GeoCountry values are valid for the GetDemographics method:
|
Remarks
For information about the demographics included for each country, see the following Help topics:
Great Britain demographic data
United States demographic data
Example
Sub CreateShadedAreaMapUsingMapPointDemographics()
Dim objApp As New MapPoint.Application
Dim objDataSet As MapPoint.DataSet
Dim objDataMap As MapPoint.DataMap
Dim objField As MapPoint.Field
'Set up application
objApp.Visible = True
objApp.UserControl = True
'Get a new demographics set to DataMap
Set objDataSet = objApp.ActiveMap.DataSets.GetDemographics()
'Get a field from the demographics
Set objField = objDataSet.Fields("Households (2000)")
'Create the data map and give it a name
Set objDataMap = _
objDataSet.DisplayDataMap(geoDataMapTypeShadedArea, _
objField, geoShowByRegion1, geoCombineByDefault, _
geoRangeTypeDiscreteEqualRanges, geoRangeOrderDefault, 15)
objDataMap.LegendTitle = "State Households"
End Sub
Note This code example is specifically for use in MapPoint North America; it is for illustration purposes only.