it would be good to add this example or a similar one to the wiki if thats possible as the instructions made little sense to me, I don't know about others
Hm. Not sure I understand why that isn't clear. The docs state
- Code: Select all
Method
addMenuItem
Parameter (name/type)
menuItem:menuItem
Description
Adds the given menu item to the bar.
Meaning the method wants a menuItem (even a link to the type definition is available) and not an array of something. That would look like this:
- Code: Select all
Method
setMenuItems
Parameter (name/type)
menuItems:menuItem[]
so in this case, it wants an array containing menuItem items (it wants all items).
Examples in the Wiki would be nice, I agree. But they take time that I can't spend on features
And there is a sample solution that among other things has exactly your case as example.