View Single Post

  #2 (permalink)  
Old 11-07-2003
Dazzer Dazzer is offline
Senior Member
Green Belt
 
Join Date: Sep 2003
Posts: 103
I had a similar problem and found I could do something along these lines with VB by importing the dataset into a recordset and then looping through each pushpin in the recordset and setting its ballon state.

Code:
Dim gappmp As New MapPoint.Application
Dim objMap As MapPoint.Map
Dim objRecords As MapPoint.Recordset

Set gappmp = CreateObject("MapPoint.Application")

    gappmp.NewMap "C:\AnyFolder\AnyMap.ptm"
    gappmp.Visible = True
    gappmp.UserControl = True

    Set objMap = gappmp.ActiveMap

        Set objRecords = objMap.DataSets.Item(1)
        Do While Not objRecords.EOF
            objRecords.Pushpin.BalloonState = geoDisplayBalloon
            'BallonState can also be geoDisplayName or geoDisplayNone
            objRecords.MoveNext
        Loop
        objRecords.MoveFirst
Hope this helps.
Reply With Quote