mappoint dataset - pushpins

itmanager
11-04-2003, 05:04 PM
i used the import wizard to import a table in the form of pushpins. is there a way globally toggle the pushpin balloons on /off and to control the content of the balloons?

i would like to initialize the balloon with the pushpin name and then toggle on the detailed address info.

i have played around with datasets and dataset but have little luck.

HELP!

ken edwards
itmanager00@msn.com

Dazzer
11-07-2003, 05:27 AM
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.

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.

 
Web mp2kmag.com
mapforums.com