Skip to main content
5-Regular Member
November 13, 2018
Solved

Is it possible to create a menu from script?

  • November 13, 2018
  • 2 replies
  • 1891 views

I want to create a Menu in Thingworx from script. I can create almost all other entities from script but I do not find a service to create a menu. 

 

 

Best answer by mneumann

No.

The EntityServices don't allow for creating a menu.

But I'll open an enhancement request for you on this one... seems like a good idea to me 🙂

 

Cheers,

Michael

2 replies

mneumann16-PearlAnswer
16-Pearl
November 13, 2018

No.

The EntityServices don't allow for creating a menu.

But I'll open an enhancement request for you on this one... seems like a good idea to me 🙂

 

Cheers,

Michael

22-Sapphire I
November 13, 2018

You can however do a dynamic creation of a menu in runtime

or if you want to persist, you could create your content in a datatable

What is your use case for a persistent menu creation at runtime.

kornelius5-Regular MemberAuthor
5-Regular Member
November 13, 2018
The use case for this is that I use menus and sub-menus to structure my landing page similar to how the Navigate landing page looks like.
For future applications I want to add additional apps (tiles) through the menu structure.
Regarding the datatable: Is there a way to bind these to a menu?
22-Sapphire I
November 13, 2018

Yes Menu's can be data driven

So you can create a datatable based off the 'MenuItem' DataShape (plus some fields you need for administrative purposes)

and then when you pull that info from the datatable, you can then assign that to a Menu widget