Force Menu Items to show up in Maya

   859   4   1
User Avatar
Member
99 posts
Joined: June 2011
Offline
Hey guys,

I have a python script which loads my HDA in maya and sets some file paths and loads some geometry based on that. I have a menu which gets populated based on the file path set and it's using a menu script. I'm running into this issue where my menu items doesn't show up in maya unless I reload the asset. The menu loads fine in Houdini though.

Force reload is an option but it seems to take really long in my case as it cooks the whole network again and I don't want that. “Sync Asset”, “Load Attributes” doesn't seem to help. The only way I could get my menu items to show up is by reloading. Is there any workaround to update the UI and load the menu items without reloading the entire asset ?
User Avatar
Staff
146 posts
Joined: Oct. 2017
Offline
You could try just syncing the attributes:

houdiniAsset -sync yourAssetNode -syncAttributes

If this doesn't work (because of dirtying issues?) we might have to convert that to force sync attributes.
Edited by juliap - Feb. 19, 2019 09:25:38
User Avatar
Member
99 posts
Joined: June 2011
Offline
Thanks for your reply but Syncing Attributes doesn't seem to help. Yea probably need the force sync option
User Avatar
Staff
146 posts
Joined: Oct. 2017
Offline
It looks like this problem is variant of the string parms/attributes with menus not behaving consistently in the maya UI problem

I will update those bugs with a link to this forum post, and if the fix for that problem does not fix this bug I will spin off another bug for this issue
User Avatar
Member
99 posts
Joined: June 2011
Offline
It would be great if we could get this fixed. Thanks a lot. I really appreciate it.
  • Quick Links