Notifications
Clear all

[Closed] How to launch nonMaxscript utility from maxscript?

Sorry for double posting but apparently my previous post wasn’t clear.
I want to launch one of the builtin (or 3rd party) utilities from the utilities panel.
The utility IS NOT a maxscript utility – if there is any file that can be associated with it, it is a DLO file.

8 Replies
 PEN

It would have needed to be exposed to Max script, does it say anything about that in the help?

 lo1

from the help file:

[left]<integer>UtilityPanel.OpenUtility <class>ClassName
[/left]
[left]Switches the control panel to the Utility Panel and opens the specified utility.

[/left]
[left]To get an array of the installed utility classes, use utilityplugin.classes
[/left]

Thanks, finally that is just what I need

Now a new problem.
I’m able to run all the utilities that I get from utilityplugin.classes except one – the one that I want to (figures )

UtilityPanel.OpenUtility 3D_Vision_viewer

I get an error

 
-- Compile error: Bad number or time syntax 
--  In line: UtilityPanel.OpenUtility 3D_

The spelling of the class should be correct – I copied it from the printed array.
Any ideas, or is there something wrong with the utility?

 lo1

Is that a native 3dsmax utility? don’t see it in my panel…

No it’s not.
But I have a few other non natives and I can run them the same way – this one is the only one with a problem

MAX Script doesn’t like name (class name) of the utility “3D_Vision_viewer” because it starts with Number. If developers can rename it, the calling of the utility has to work.

From the maxscript help under Names heading:

Quoted Names[left]Names set in single quotes allow you to write names that contain illegal identifier characters, such as spaces and other punctuation. They are primarily intended for specifying 3ds Max object classes and properties that have special characters in their names.
So try this instead:

UtilityPanel.OpenUtility '3D_Vision_viewer'

-Eric
[/left]

And it works.

Once again I bow down before collective knowledge

Live free and prosper …guys.