License Delivery maintenance is expected to occur on Saturday, November 30, between 8 AM and 11 AM CET. This may cause a short 3-hours outage in which license-related tasks: license key upload, download, update, SSA validation, access to the license pool and Graphisoft ID authentication may not function properly. We apologize for any inconvenience.
Archicad C++ API
About Archicad add-on development using the C++ API.

Why is the second menu item, a sub menu

Anonymous
Not applicable
I don't understand what causes a string to be a sub menu rather than a menu item. My resource looks like:

'STR#' 32500 "Menu strings" {
/* [ ] */ "ITI"
/* [ 1] */ "Import Updates^EL"
/* [ 2] */ "Lookup Element^EL"
}

When I load this menu with:

err = ACAPI_Register_Menu (32500, 32520, MenuCode_UserDef, MenuFlag_Default);

I get a new menu on the menubar called "ITI", a submenu called "Import Updates^EL" and a menu item on the sub menu called :Lookup Element". What I want is "Import Updates" and "Lookup Element" to be menu items under the ITI menu.

The documentation doesn't sya anything about how to do this, although it sort-of implies that indentation of the strings is the key. But that can't be right because mine are all indented the same.
1 REPLY 1
Ralph Wessel
Mentor
LesWoolsey wrote:
My resource looks like:
'STR#' 32500 "Menu strings" {
/* [ ] */ "ITI"
/* [ 1] */ "Import Updates^EL"
/* [ 2] */ "Lookup Element^EL"
}
I get a new menu on the menubar called "ITI", a submenu called "Import Updates^EL" and a menu item on the sub menu called :Lookup Element".
Make a separate STR# resource for each menu:
'STR#' 32500  "First menu item" {
	/*[  ]*/	"ITI"
	/*[ 1]*/	"Import Updates^EL"
}


'STR#' 32501  "Second menu item" {
	/*[  ]*/	"ITI"
	/*[ 1]*/	"Lookup Element^EL"
}
Ralph Wessel BArch
Software Engineer Speckle Systems