How to get sightPtr
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-22
11:25 AM
- last edited on
2021-09-15
10:33 AM
by
Noemi Balogh
I would like to export model from ARCHICAD. Different from ModelAccess_Test module which triggers the functions by "save", the requirement is to click the button on the menu. However, if I install menu handler, I could not get Modeler::SightPtr like Install_FileTypeHandler3D. I was wondering how to get Modeler::SightPtr in some other ways.
Thanks in advance.
Solved! Go to Solution.
- Labels:
-
Add-On (C++)
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-22 12:13 PM
If you register a new menu item from an Add-On by default it will be enabled (not gray) only when a 2D view (floorplan) is active.
But you can enable your menu items under any other view types if you modify the resource string of your menu item in your GRC file. Simply add ^E3 (= Enable in 3D) after the string title of your menu item into the GRC and it won't be gray and you will be able to use ACAPI_3D_GetCurrentWindowSight:
'STR#' 32500 "My menu strings" { /* [ 1] */ "My Main Menu" /* [ 2] */ "My Menu^E3" }See more informations here:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-22 11:41 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-22 11:41 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-22 12:13 PM
If you register a new menu item from an Add-On by default it will be enabled (not gray) only when a 2D view (floorplan) is active.
But you can enable your menu items under any other view types if you modify the resource string of your menu item in your GRC file. Simply add ^E3 (= Enable in 3D) after the string title of your menu item into the GRC and it won't be gray and you will be able to use ACAPI_3D_GetCurrentWindowSight:
'STR#' 32500 "My menu strings" { /* [ 1] */ "My Main Menu" /* [ 2] */ "My Menu^E3" }See more informations here:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-22 12:29 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-23 11:53 AM
Tibor wrote:Hi Tibor.
Hi scandi,
If you register a new menu item from an Add-On by default it will be enabled (not gray) only when a 2D view (floorplan) is active.
But you can enable your menu items under any other view types if you modify the resource string of your menu item in your GRC file. Simply add ^E3 (= Enable in 3D) after the string title of your menu item into the GRC and it won't be gray and you will be able to use ACAPI_3D_GetCurrentWindowSight:'STR#' 32500 "My menu strings" { /* [ 1] */ "My Main Menu" /* [ 2] */ "My Menu^E3" }See more informations here:http://archicadapi.graphisoft.com/documentation/required-resources
Could you please tell me how to enable the button only in 3D window please? Is there a disable-2D string?
Thanks in advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-23 11:59 AM
scandi wrote:I find it! "^D2" will work. Maybe D2 means "Disable in 2D".
Tibor wrote:Hi Tibor.
Hi scandi,
If you register a new menu item from an Add-On by default it will be enabled (not gray) only when a 2D view (floorplan) is active.
But you can enable your menu items under any other view types if you modify the resource string of your menu item in your GRC file. Simply add ^E3 (= Enable in 3D) after the string title of your menu item into the GRC and it won't be gray and you will be able to use ACAPI_3D_GetCurrentWindowSight:'STR#' 32500 "My menu strings" { /* [ 1] */ "My Main Menu" /* [ 2] */ "My Menu^E3" }See more informations here:http://archicadapi.graphisoft.com/documentation/required-resources
Could you please tell me how to enable the button only in 3D window please? Is there a disable-2D string?
Thanks in advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-23 01:31 PM
scandi wrote:Follow the link Tibor gave you - it provides all the documentation for the menu resources:
I find it! "^D2" will work. Maybe D2 means "Disable in 2D".
Central Innovation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-23 06:54 PM
Ralph wrote:Thank you. I didn't notice that link.
scandi wrote:Follow the link Tibor gave you - it provides all the documentation for the menu resources:
I find it! "^D2" will work. Maybe D2 means "Disable in 2D".http://archicadapi.graphisoft.com/documentation/required-resources