求助!调试程序是出错。
Private Sub Map1_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single)Dim Rect As New MapObjects2.Rectangle
If Toolbar1.Buttons(2).Value = 1 Then
' zoom in
Set r = map1.TrackRectangle 总是弹出"未找到方法或数据成员"
If Not r Is Nothing Then map1.Extent = r 同上
ElseIf Toolbar1.Buttons(1).Value = 1 Then
' pan
map1.Pan
ElseIf Toolbar1.Buttons(3).Value = 1 Then
Set Rect = map1.Extent 同上
Rect.ScaleRectangle (2#)
map1.Extent = Rect 同上
End If
End Sub