Maxsurf does not include facilities for its own Visual Basic Editor, writing scripts is done externally through the Visual Basic Editors in programs such as Excel and AutoCAD. In the Microsoft Office products this is performed via the Tools | Macro | Visual Basic Editor command from the main menu.
Open the Visual Basic Editor and add the following text to the content of a file open within this window.
Sub Hello()
MsgBox "Hello World"
End Sub
To run this macro, locate the cursor within the code and select the command Run | Run Sub/Userform from the main menu. You will see a simple dialog saying “Hello World”.
For more information on the basics of creating macros, see the Further Reading section on page 17.