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

Problem with geoshowbyzoomlevel in C#

This is a discussion on Problem with geoshowbyzoomlevel in C# within the Development forums, part of the MapPoint Desktop Discussion category; I'm trying to use DisplayDataMap with geoshowdataby=geoshowbyzoomlevel but not work; give an error geography type I've try same code with ...

  1. #1
    rlisario is offline Junior Member Yellow Belt
    Join Date
    Jul 2007
    Location
    Brescia (ITALY)
    Posts
    13

    Question Problem with geoshowbyzoomlevel in C#

    I'm trying to use DisplayDataMap with geoshowdataby=geoshowbyzoomlevel but not work; give an error geography type

    I've try same code with same import file with geoshowdataby=georegion1 or with geoshowdataby=georegion2 or with geoshowdataby=geopostal1 and it's all ok.

    The file that import has name, latitude, longitude and data.

    The same file imported with MapPoint Application work with zoom level

    Somebody has used DisplayDataMap with geoshowdataby=geoshowbyzoomlevel ?

    Thanks,
    Rinaldo

  2. #2
    Eric Frost's Avatar
    Eric Frost is offline Administrator Black Belt
    Join Date
    Jul 1992
    Posts
    5,094
    Blog Entries
    4

    Re: Problem with geoshowbyzoomlevel in C#

    Have you tried importing the file through the MapPoint wizard interface (not code) and choose the zoom by all levels option - does it give you that option?

    Can you post a sample part of the file as an attachment here?

    Eric
    ~ Order MapPoint MapPoint 2013 Here and Get Free Access to the MapForums Downloads ~
    ~~
    ~ Upgrade to Get Access to the MapForums Downloads ~

  3. #3
    rlisario is offline Junior Member Yellow Belt
    Join Date
    Jul 2007
    Location
    Brescia (ITALY)
    Posts
    13

    Re: Problem with geoshowbyzoomlevel in C#

    Dear Eric,

    The strangeness that is through the MapPoint wizard interface to import the same file csv (that i've attach) is all ok.

    The my code in C# is:

    object[,] arrObjCampi = new object[4, 2];
    arrObjCampi[0, 0] = "Nome";
    arrObjCampi[0, 1] = MapPoint.GeoFieldType.geoFieldName;
    arrObjCampi[1, 0] = "Latitudine";
    arrObjCampi[1, 1] = MapPoint.GeoFieldType.geoFieldLatitude;
    arrObjCampi[2, 0] = "Longitudine";
    arrObjCampi[2, 1] = MapPoint.GeoFieldType.geoFieldLongitude;
    arrObjCampi[3, 0] = "Fatturato";
    arrObjCampi[3, 1] = MapPoint.GeoFieldType.geoFieldData;

    m_ds1 = pMappa.ActiveMap.DataSets.ImportData(System.IO.Pat h.Combine(Application.StartupPath, "provaRivenditori2.csv"), arrObjCampi, MapPoint.GeoCountry.geoCountryItaly, MapPoint.GeoDelimiter.geoDelimiterSemicolon, 0);
    object objNomeParametro = "Fatturato";
    object missing = System.Type.Missing;

    MapPoint.Field objParametro = m_ds1.Fields.get_Item(ref objNomeParametro);
    MapPoint.DataMap dm = m_ds1.DisplayDataMap(MapPoint.GeoDataMapType.geoDa taMapTypeShadedArea, objParametro, MapPoint.GeoShowDataBy.geoShowByZoomLevel, MapPoint.GeoCombineDataBy.geoCombineByAdd, MapPoint.GeoDataRangeType.geoRangeTypeContinuous, MapPoint.GeoDataRangeOrder.geoRangeOrderDefault, 13, 0, missing, missing, missing, missing, missing);

    Thanks for help,
    Rinaldo
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Problem with geoshowbyzoomlevel in C#
    By rlisario in forum MapPoint Desktop Discussion
    Replies: 0
    Last Post: 11-06-2007, 06:23 AM
  2. geoShowByZoomLevel - Not zooming?
    By mikechayes in forum MapPoint Desktop Discussion
    Replies: 0
    Last Post: 02-13-2003, 02:45 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