Custom UI register/unregister dialog bar
Hi everybody, new to this forum, I'm coding a script to help myself with some stuffs I like to use and for that I'd like to make a floating toolbar, dockable to the Max UI just by clicking/unclicking one button.
I don't know why, but at first this worked (By clicking the button and uncheking it back)
But for some unknown reasons I now got an error without changing anything in the code :
" -- Runtime error: Requires a Rollout or RolloutFloater, got: undefined"
Here is the code :
macroScript Toolbox_Utility_Script category:"Toolbox Utility" toolTip:"Toolbox Utility" ( local isOpen = false on execute do ( if isOpen then ( cui.UnRegisterDialogBar Toolbox_Utility closerolloutfloater Toolbox_Utility isOpen = false ) else ( Toolbox_Utility = newRolloutFloater "Toolbox" 160 1024 cui.RegisterDialogBar Toolbox_Utility style:#(#cui_dock_all, #cui_floatable, #cui_handles) cui.DockDialogBar Toolbox_Utility #cui_dock_left isOpen = true ) ) on isChecked return isOpen )
Thanks for lighting me on this! :)