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 3 of 3

Use MapPoint NA and MapPoint EU in the same application?

This is a discussion on Use MapPoint NA and MapPoint EU in the same application? within the MapPoint Desktop Discussion forums, part of the Map Forums category; Has anyone been able to successfully use North America and Europe in the same application? I can create an instance ...

  1. #1
    1.21Gigawatts is offline Junior Member White Belt
    Join Date
    Apr 2005
    Posts
    8

    Use MapPoint NA and MapPoint EU in the same application?

    Has anyone been able to successfully use North America and Europe in the same application?

    I can create an instance of the MapPoint NA Application object with this:

    Code:
    MapPoint.ApplicationClass theApp = new MapPoint.ApplicationClass();
    This works fine. I also want to create an instance of the MapPoint Europe Application object, which I assumed had the same interface.

    Code:
    Type mpType = Type.GetTypeFromProgID("MapPoint.Application.EU", false);
    object mpEu = Activator.CreateInstance(mpType);
    MapPoint.Application mpEuApp;
    if(mpEu is MapPoint.Application)
    {
       // MapPoint._Application also works
       // MapPoint.ApplicationClass does not work.
    
       mpEuApp = (MapPoint.Application)mpEu;
    }
    This also, works but MapPoint.Application and MapPoint._Application have different interfaces than MapPoint.ApplicationClass so I can't use them interchangeably nor do they even support all of the methods. I'm stuck!

  2. #2
    Winwaed's Avatar
    Winwaed is offline Mapping-Tools.com Black Belt
    Join Date
    Feb 2004
    Location
    Irving,Texas
    Posts
    1,859
    Blog Entries
    60
    In C++, I use


    Code:
    	_ApplicationPtr myAppPtr;
    
    	if ( myAppPtr.CreateInstance(appObjName) != 0)
    	{
    		// error
    	}
    and set appObjName to "MapPoint.Application.NA" or "MapPoint.Application.EU"

    I have an application that successfully queries the registry to find which versions are available, and then gives the user the choice.
    (unfortunately it doesn't work for selecting 2002 vs 2004)
    But it does work for selecting Europe vs. North America.


    Richard
    Winwaed Software Technology LLC
    http://www.winwaed.com
    See http://www.mapping-tools.com for MapPoint Tools

  3. #3
    1.21Gigawatts is offline Junior Member White Belt
    Join Date
    Apr 2005
    Posts
    8
    The problem I am having is not with creating instances (either NA or EU) of these applications. I can do that just fine. The problem I am having is that the instances don't have the same interface. So I can't decide which one I want to load and then assign it to some generic reference (which is what I'd like to do).

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Using Mappoint with Web Application
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 0
    Last Post: 06-02-2004, 08:29 AM
  2. Cant See Mappoint.Application from VB
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 2
    Last Post: 04-15-2004, 11:15 AM
  3. Creating an application with mappoint within vb
    By blackmap in forum MapPoint Desktop Discussion
    Replies: 3
    Last Post: 12-16-2002, 07:15 PM
  4. Hi, I need help getting MapPoint.Application to....
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 1
    Last Post: 01-23-2002, 07:10 AM
  5. I am trying to use the Mappoint in my application ....
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 1
    Last Post: 12-03-2001, 10:53 PM

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 84 85 86 87 88 89 90 91 92 93 94 95 96