文档介绍:Page 1 Thursday, December 9, 1999 2:22 PM
CONTENTS INDEX MEET MTB UGUIDE 1 UGUIDE 2 SC QREF HOW TO USE
29
Advanced Macros
■ Advanced Macros Overview, 29-2
■ Using Variables, 29-2
■ Using Arguments, 29-4
■ Using mands, 29-6
■ The Structure of a Local Macro, 29-8
■ Invoking a Local Macro, 29-10
■ Example of a Local Macro, 29-10
■ Writing a Template, 29-12
■ Declaration Statements, 29-13
■ Using Text Data, 29-15
■ Using Suffixed Variables, 29-17
■ Using Free Variables, 29-20
■ Finding the Variable Data Type, 29-23
■ What Next?, 29-25
MINITAB User’s Guide 1 29-1
CONTENTS INDEX MEET MTB UGUIDE 1 UGUIDE 2 SC QREF HOW TO USE
Page 2 Thursday, December 9, 1999 2:22 PM
CONTENTS INDEX MEET MTB UGUIDE 1 UGUIDE 2 SC QREF HOW TO USE
Chapter 29 Advanced Macros Overview
Advanced Macros Overview
Local macros are plex than global macros, and thus harder to write. However,
they are more powerful and flexible. If you need to write a plex macro, or if
you want a macro which you can execute like a mand, then you should
write a local macro. If you are new to writing macros, you should read Chapter 28,
Introducing Simple Macros.
Local macros can use temporary variables, arguments, and mands to enhance
the processing capabilities of the macro. Local macros also have a different structure
that allows you to include areas for defining mands and the variables.
Local Macro Elements
Local macros have the capability to handle several elements which improve the
processing capabilities of your macro. These following three elements are mentioned
throughout this chapter, and explained further in the next three sections:
■ Variables - see Using Variables on page 29-2
■ Arguments - see Using Arguments on page 29-4
■ mands - see Using mands on page 29-6
Local Macro Structure
Template
Global macros use the template for naming purposes. Local macros use the template for
naming the macro, b