Phone: 905 409-1589
RSS LinkedIn Twitter Twitter
Dot Net/Max Script:
Max Script / Dot Net Tutorials:
Here I will create a list of tutorials that cover some of the usage of Dot Net class', objects and controls in Max Script. I will also try to explain how to find your way around Dot Net and how to get started.

If you encounter any errors on these pages or any others at please email me the link to the page and the error that you have encountered, thanks. Email

What is Dot Net?
In Max 9, when Microsoft moved to 64 bit and dropped Active X, Dot Net (or .net) was added as their object oriented development framework. Active X controls still work in Max 9, 2008 and even 2009 but only in the 32bit versions. In the 64bit version Dot Net must be used. Because Max is so tied to windows it also had to make the change to ensure that features kept working like the Layers Manager that uses the Dot Net Listview control and many others. Active X was implemented into Max script but not very well and Active X had many issues of it's own. Dot Net is far easier to work with but takes a fair amount of work to get used to and is not for the beginner Max scripter.

Dot Net is a frame work of objects that are used to control how things look on screen, how data is managed or how your system is setup. I can't go into everything that you can do with Dot Net as I don't know it to that level, I'm not sure that any one person can. For people starting out with Dot Net in Max script it is usually to try and enhance the look and feel of the user interfaces that they are creating for production tools and system.

You can find more information about Dot Net at the MSDN developers site

Possible Uses of Dot Net:
This again would be a very long list that really doesn't need to be covered. Some of the most used will be dotNetControls. These are UI items like a button or listBox, however they are far more advanced. dotNetControls that you are likely to use will be listView, treeView, button or maybe picturBox. You can see the usage of these controls in Max, the listView is used in Layer Manger and treeView in Scene Explorer. Scene explorer is actually a combination of the two but this can't be done via Max script only. C#, VB or some other language would have to be used to create the hybrid control and then called by Max.
Getting started:
There are several way to initialize a Dot Net object. dotNetClass, dotNetObject, dotNetControl, dotNet.loadAssembly. To which you should be using is a bit hard to explain, mostly because I don't fully understand it my self in all cases at this point. There are some that do make sense like Dot NetControl. Any time that you want to add a UI control object to a tool that you are creating you will be using

dotNetControl internalScriptName "a dot net string defining the path to the control"

For more information about this consult the Max script help. Search for Dot Net and there will be lots of information about it.

aColor = dotNetClass "system.drawing.color"
aPen = dotNetObject "system.drawing.pen" aColor 2
dotNetControl aList ""
dotNet.loadAssembly "system.xml"
Sources / Reference:
Dot Net Pros:

Some of the pros might not have sites but searching the forums that are listed will result in finding posts from them on the subject.