Previous Next        Current Page: NeXtMidas Training / Macros - Part 1 (Basics) / Macro Basics / Lab 2 - Macro Basics / Solution
back
Start Here   
Background   
Common Midas Concepts   
Getting Started - Part 1   
Getting Started - Part 2   
Working with Files   
Option Trees   
Macros - Part 1 (Basics)   
   - Macro Basics   
      - What is a Macro?   
      - Types of Macros   
      - Local vs Global Results   
      - Macro Structure   
      - Lab 1 - Macro Basics   
         - Instructions   
         - Solution   
      - Lab 2 - Macro Basics   
         - Instructions   
         - Solution   
   + Loops and Control Structures   
   + Procedures and Subroutines   
   + Pipes in a Macro   
   + Messages in a Macro   
Macros - Part 2 (Graphics)   
NetBeans - Part 1 (Setup)   
NetBeans - Part 2 (GUIs)   
NetBeans - Part 3 (Profiler)   
Eclipse - Part 1 (Setup)   
Eclipse - Part 2 (GUIs)   
Primitives   
WebStart   
Maps & Imagery   
X-Midas Interoperability   
RMIF & Remoting   
Installing NeXtMidas   
Support & Maintenance   
File Handlers   


  • Lab 2 (solution):
    • For this lab you should have made an option tree called TRAIN (see the module on Option Trees for details), and added it to your path.
      nM> path add train
    • Then you should have copied your macro to the mcr directory of the option tree.
    • Once the option tree was setup and mcrlab1.mm was copied to it, you should have added the command to the dictionary using UPDATE.
      nM> update mcrlab1
      Option tree (USER, SITE, UCL, etc): [] -> train
      MYCOMMAND Abbreviation: [MCRLAB1] -> 
      Support [M] -> M
      Number of arguments [0] -> 3
      Default 1 [] -> NAME=
      Default 2 [] -> FEET=
      Default 3 [] -> INCHES=
      nM>

back