View Single Post

  #7 (permalink)  
Old 08-16-2002
John Meyer's Avatar
John Meyer John Meyer is offline
Senior Member
Blue Belt
 
Join Date: Jul 2002
Posts: 479
Ok, this question seems to come up alot so here is the code to get the balloons to pop up for each pushpin on a mappoint map. In Visual Basic make sure you have a Reference to Microsoft Mappoint 9.0 Object Library (North America) I put this code in a command button as an example. Keep in mind there is no error checking here and if you were not running mappoint at all you would get an error.

Private Sub Command1_Click()
Dim objmap As MapPoint.Map
Dim objDataSet As MapPoint.DataSet
Dim objRecordset As MapPoint.Recordset

Set objmap = GetObject(, "MapPoint.Application").ActiveMap
For Each objDataSet In objmap.DataSets
Set objRecordset = objDataSet.QueryAllRecords
Do Until objRecordset.EOF
objRecordset.Pushpin.BalloonState = geoDisplayBalloon
objRecordset.MoveNext
Loop
Next

End Sub
__________________
John
http://www.support-pc.com

Order MapPoint 2006 Here
https://secure.mp2kmag.com/?refer=support-PC
Reply With Quote