ValueCount property

Returns the total number of values mapped. Returns 0 if the DataRangeType property of a DataRanges collection is geoRangeTypeContinuous or geoRangeTypeContinuousLog. Read-only Long.

Applies to

Objects: DataRange

Syntax

object.ValueCount

Parameters

Part Description
object Required. An expression that returns a DataRange object.

Remarks

The ValueCount property is useful for records that have more than one value, such as those used for Column Chart or Series Column Chart maps. Some of the values of a record may fall within the range and be mapped, while others may fall outside the range and not be mapped.

If the IsGeographyForEveryZoomLevel property is True for the DataMap object, then the current zoom level also affects the count returned by the ValueCount property. For example, if data for the United States is currently shown at the state level, this property may return 10 (the number of values mapped at the state level). If the user zooms in and data is shown at the county level, then this property may return 1,000 (the number of values mapped at the county level).

If multiple fields are mapped, such as for Chart maps, the ValueCount property returns a count of all values. For example, the number of United States counties mapped may return 3,000 for a Chart map with 3 fields.

To return the total number of records mapped, use the RecordCount property of the DataMap object.

Example

    Sub GetInfoAboutDataMap()
    Dim objApp As New mappoint.Application
    Dim objDataMap As mappoint.DataMap
    Dim objDataSet As mappoint.DataSet

    'Set up application and objects to use     objApp.Visible = True     objApp.UserControl = True
    'Let user create a data map     Set objDataMap = objApp.ActiveMap.DataSets.ShowDataMappingWizard()
    'Get information about the data map     MsgBox "Values mapped in first range (0 if continuous): " & _       objDataMap.DataRanges(1).ValueCount   End Sub