mapId is reset to 0 (API_UndefinedMap) [SOLVED TEMPORARILY]
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-11-06
09:18 AM
- last edited on
‎2023-08-01
06:57 PM
by
Doreena Deng
‎2013-11-06
09:18 AM
I don't know if this is a bug or intentional. Here is the code:
navi_map_id = API_PublisherSets; //... set.mapId = navi_map_id; set.wantsExtraInfo = (navi_map_id == API_PublisherSets) ? 1 : 0; DBPrintf("1 - set.mapId: %d (%d)", set.mapId, navi_map_id); err = ACAPI_Environment(APIEnv_GetNavigatorSetID, &set, &i); DBPrintf("2 - set.mapId: %d (%d)", set.mapId, navi_map_id);And here is the output:
1 - set.mapId: 5 (5) 2 - set.mapId: 0 (5)As you can see, the value of set.mapId was reset to 0.
~ReignBough~
ARCHICAD 27 INT (since AC18)
Windows 11 Pro, AMD Ryzen 7, 3.20GHz, 32.0GB RAM, 64-bit OS
ARCHICAD 27 INT (since AC18)
Windows 11 Pro, AMD Ryzen 7, 3.20GHz, 32.0GB RAM, 64-bit OS
Labels:
- Labels:
-
Add-On (C++)
3 REPLIES 3

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-11-13 05:25 PM
‎2013-11-13
05:25 PM
Hi,
The set is a local object, so if you change it's mapId it won't affect the application's navigator set.
That's why it gives you the unmodified mapId if you get the navigator set again with APIEnv_GetNavigatorSetID.
Why do you want to change the mapId?
Best Regards,
Tibor
The set is a local object, so if you change it's mapId it won't affect the application's navigator set.
That's why it gives you the unmodified mapId if you get the navigator set again with APIEnv_GetNavigatorSetID.
Why do you want to change the mapId?
Best Regards,
Tibor
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-12-11 09:23 AM
‎2013-12-11
09:23 AM
If my understanding is correct, ACAPI_Environment(APIEnv_GetNavigatorSetID) will retrieve the information of a navigator set determined by the mapId . But if the returned information gives me a value of 0 in the mapId (which is API_UndefinedMap ) after I called the function, this means that the navigator set that was returned to me is undefined (or unknown).
mapId . I just want to check and/or use the value of the mapId after the call. But it became 0.
Tibor wrote:I am not changing the
Why do you want to change the mapId?
~ReignBough~
ARCHICAD 27 INT (since AC18)
Windows 11 Pro, AMD Ryzen 7, 3.20GHz, 32.0GB RAM, 64-bit OS
ARCHICAD 27 INT (since AC18)
Windows 11 Pro, AMD Ryzen 7, 3.20GHz, 32.0GB RAM, 64-bit OS

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-12-13 01:13 PM
‎2013-12-13
01:13 PM
Hi,
I've checked that, and you're right.
ACAPI_Environment(APIEnv_GetNavigatorSetID,…) function retrieves only the following informations of the navigator:
name, guid, rootGuid and path if it's exists.
Unfortunately it always sets the mapId property to 0. But the mapId is an input parameter here, so you should know it before calling the function.
Anyway, we will fix this bug in the next API version, the output's mapId will be the same as the input's mapId of course. Thanks for pointing out this issue!
Regards,
Tibor Lorántfy
I've checked that, and you're right.
ACAPI_Environment(APIEnv_GetNavigatorSetID,…) function retrieves only the following informations of the navigator:
name, guid, rootGuid and path if it's exists.
Unfortunately it always sets the mapId property to 0. But the mapId is an input parameter here, so you should know it before calling the function.
Anyway, we will fix this bug in the next API version, the output's mapId will be the same as the input's mapId of course. Thanks for pointing out this issue!
Regards,
Tibor Lorántfy