Global Mapper v25.0

GM is not saving file correctly

mjmfgm
mjmfgm Global Mapper UserTrusted User
edited November 2008 in Technical Support
I just noticed that GM version 10.1 is not saving changed data when exporting to MP format. I changed the type from road to pipeline and saved the file. After that I exported to polish format and opened the file in a text editor. GM did not re-wrote the new type as well as any other information ( see below).

........................................old data ........................................
[RGN40]
Marine=Y
Type=0x0307
Levels=2

........................................new data ......................................
RGN40]
Marine=N
Type=0x28
Levels=4

......................................GM Date after export ...................................
[RGN40]
Marine=Y
Type=0x0307
Levels=2

.........................................MP file.....................................................
[IMG ID]ID=02859944 Name=Test Elevation=F LBLcoding=9 Codepage=1252 Marine=N Copyright=Fred Test Preprocess=F ;TreSize=3000 POIIndex=N Transparent=Y Levels=4 Level0=24 Level1=22 Level2=20 Level3=18 Zoom0=1 Zoom1=2 Zoom2=3 Zoom3=4 [END-IMG ID] :confused:[/img]

Comments

  • global_mapper
    global_mapper Administrator
    edited November 2008
    When you loading your data from a MP file it automatically came with an explicit MP_TYPE field. Since the value of an explicit MP_TYPE attribute overrides any default MP_TYPE value for a Global Mapper type, just changing the Global Mapper type won't change the type output to an exported MP file. You also need to update (or delete) the existing MP_TYPE attribute for the feature prior to export.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • mjmfgm
    mjmfgm Global Mapper User Trusted User
    edited November 2008
    Hm makes sense, I will give it a try. Most other application when you change type definition back to standard they write the new data and not keep the old data.

    Thanks Mike.
  • mjmfgm
    mjmfgm Global Mapper User Trusted User
    edited November 2008
    One more thing here to note, why is the level information not correct, or the the Marine type "Y" not correct ?
  • global_mapper
    global_mapper Administrator
    edited November 2008
    All of the attributes that come in on MP import override any attributes provided in a default attribute list for a Global Mapper type. There has to be some kind of priority assigned to different levels of attribution and any attributes explicitly specified for a feature take preference. If you strickly want type-based attribute to be used, you can select all of the features when you load them, then edit them and delete the MP-derived attributes (i.e. MP_TYPE, LEVELS, and MARINE).

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • mjmfgm
    mjmfgm Global Mapper User Trusted User
    edited November 2008
    Mike I checked this out now and found out when you export via the "Draw Box" command MP 10.1 does not write the changed information into the "Polish format file. I changed the attribute setting for the MP_TYPE and saved the file. Then I exported an area to vector - Polish formate (xxx.mp) and opened the file with a text editor and all the old information is still there. None of the new information is showing up.

    Could you please look into this please, thanks Mike.
  • global_mapper
    global_mapper Administrator
    edited November 2008
    Mike,

    When you say that you changed the attribute setting for MP_TYPE, where did you change that at? Keep in mind that if you change the MP_TYPE attribute for a type in the Configuration dialog, that will only apply to features of that type if the features themselves don't already have a MP_TYPE attribute value (you can check this by selecting a feature with the Feature Info tool).

    How you specify the bounds for an export (i.e. Draw Box or otherwise) should not have any affect on the attributes that are written out.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • mjmfgm
    mjmfgm Global Mapper User Trusted User
    edited November 2008
    Okay as I explaind prior, I expected the data to change in the exported "xxx.mp" file after I made a change in the MP_TYPE attribute settings and saved the file in GM.

    When you make changes to any-type of data that change should be reflected, if it does not then there is something wrong. So again I imported a shape file, selected a line feature from the "Vector Option". Than I went to the configuration window and selected the Line Style tab, in the line style tab, I created a custom ( NEW ) type named "GMU Boundary". I than assigned an "MP_TYPE" to that new custom type.

    So far so good new type is showing up correctly, the problem lies in that when you change the custom hex code. The exported vector does not update with polygon and line styles.

    If I only had to change one (1) item I would not even bother writing this. However I have quite a few to change and would like to do that via GM.

    Thanks Mike.
  • global_mapper
    global_mapper Administrator
    edited November 2008
    Mike,

    First just to clarify how the MP_TYPE value assignment works when you export loaded data to a new MP file, here is the order in which things are checked in order to assign the Type= value in an exported MP file:

    1) If the feature being exported has a MP_TYPE value in its attribute list, that is used, otherwise,
    2) If the default attribute list (as set on the * Styles tab of the Configuration dialog) for the classification assigned to the feature has a MP_TYPE value, then that value is used, otherwise,
    3) If the assigned classification is a built-in type and there is a defined default MP type mapping in Global Mapper for that type, that is used, otherwise
    4) There is no known MP type to use for the feature, so the name of the feature classification is saved as the TYPE= value in the MP file in case the type mapping is defined in the RGNTypes.txt file accompanying cGPSMapper.

    From what you describe, I am gathering the following steps:

    1) Load Shapefile
    2) From the Control Center, select the Shapefile, press Options, then assign a type to all of the features in the Shapefile
    3) On the Line Styles tab of the Configuration dialog, create a new 'GMU Boundary' type and provide a default MP_TYPE value for that type.

    What I'm not understanding is what type are you assigning to the features in the Shapefile in step 2? I would expect you to do step 3 first, then assign the Shapefile featuers to your new custom 'GMU Boundary' type. Also, do the features in the Shapefile already have attributes explicitly associated with each feature, like MP_TYPE, that would override the default attribute list settings for a type based on the priority list described above?

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com