Welcome to MapForums!

Register, sign in, or use Facebook Connect above to join in and participate in the forum.

When you are signed in, this message, the ads in this row, and the red-underlined link ads all go away.

Subscribe to receive our newsletter.
Subscribe Unsubscribe
Results 1 to 4 of 4

Creating an application with mappoint within vb

This is a discussion on Creating an application with mappoint within vb within the MapPoint Desktop Discussion forums, part of the Map Forums category; Hi all! Am quite new to mappoint and I am trying to programm an application with the active x. What ...

  1. #1
    blackmap is offline Member Yellow Belt
    Join Date
    Dec 2002
    Posts
    39

    Creating an application with mappoint within vb

    Hi all!

    Am quite new to mappoint and I am trying to programm an application with the active x. What I can already do is to put up am map, zoomto a certain adress etc.

    What I am looking now for is:

    -How can I add the legend to my app/ control?
    -How can I click on a certain pushpin, make an odbc connection and show some information from the odbc database ?
    -This is a mappoint user forum, right? Is there a forum just for developers?


    Thank you very much!


    Peter

  2. #2
    John Meyer's Avatar
    John Meyer is offline Senior Member Blue Belt
    Join Date
    Jul 2002
    Posts
    478
    You are in the right forum.

    To add the legend
    Code:
    MapPointControl1.PaneState = geoPaneLegend
    To work with a Pushpin that you have selected.

    Code:
    Dim objmap As MapPointctl.Map
    Dim objPushpin As MapPointCtl.Pushpin
    
    Set objmap = MapPointControl1.ActiveMap
          'Make sure the item selected on the map is a pushpin
        If TypeOf objmap.Selection Is Pushpin Then
          Set objPushpin = MapPointControl1.Selection       
          'Do Something
        End If

  3. #3
    blackmap is offline Member Yellow Belt
    Join Date
    Dec 2002
    Posts
    39

    Select pushpin and connect to databse

    Hi John,

    thanks a lot for your answers!

    When I paste the last code snipplet into the mouse_down event of the mappoint control it causes a mean crash. Do you have an idea?

    What I want to do is:

    Click on a pushpin in my map, when it's sapushpin I want to connect to an odbc database and sho some information in a dialog.


    Peter

  4. #4
    John Meyer's Avatar
    John Meyer is offline Senior Member Blue Belt
    Join Date
    Jul 2002
    Posts
    478
    I would put the code in the "SelectionChange event"

    At the point in the code sample that says "Do Something" call a subroutine, passing it the pushpin object.

    You can not run your code inside the event procedure or you will get the "Server Busy Error"

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Creating a setup project in VB.net to distribute Mappoint
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 3
    Last Post: 10-04-2005, 03:24 PM
  2. tip: creating object model of mappoint and SQL command
    By Wilfried in forum MapPoint Desktop Discussion
    Replies: 0
    Last Post: 02-24-2005, 01:00 PM
  3. MapPoint Programming.... Creating a Route
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 7
    Last Post: 10-12-2004, 01:34 AM
  4. Creating COM add-ins for MapPoint using C#
    By ratsey in forum MapPoint Desktop Discussion
    Replies: 3
    Last Post: 11-12-2003, 11:44 AM
  5. Are there any plans for creating a mappoint active....
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 1
    Last Post: 07-30-2001, 07:01 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83