EasyManuals Logo

Juniper SYSTEM BASICS - CONFIGURATION GUIDE V 11.1.X User Manual

Juniper SYSTEM BASICS - CONFIGURATION GUIDE V 11.1.X
640 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #509 background imageLoading...
Page #509 background image
<# "error: " $ env.getErrorCommand $ "\n" #>
<# "status: " $ env.getErrorStatus $ "\n\n" #>
<# endsetoutput #>
<#endtmpl#>
When you run the macro, the error command is blank and the error status is Status
is not available:
ERX-40-4a-cc#macro b.mac errorStatusTest
Macro 'errorStatusTest' in file 'b.mac' starting execution (Id: 17)
error:
status: "Macro is not onError. Status is not available"
Macro 'errorStatusTest' in file 'b.mac' ending execution (Id: 17)
Variables
A local variable enables you to store a value used by the macro while it executes.
The macro can modify the value during execution. Local variables can be integers,
real numbers, or strings. The initial value of local variables is zero.
Like macros, local variables must have a name consisting only of letters, numbers,
or the underline character (_). The variable name must not begin with a number.
You must not use a reserved keyword as a variable name. A line that ends with a
variable needs a new line character at the end of the line.
Literals
A literal is an exact representation of numeric or string values. Every number is a
literal. Place single or double quotation marks around a string to identify it as a string
literal. You can specify special characters within a literal string by prefacing them
with a backslash as follows:
\quotation mark
\double quotation
mark
\ttab
\rcarriage return
\nnew line
\0string end
\\backslash
Examples 42
98.6
string literal
Writing Macros 479
Chapter 8: Writing CLI Macros

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Juniper SYSTEM BASICS - CONFIGURATION GUIDE V 11.1.X and is the answer not in the manual?

Juniper SYSTEM BASICS - CONFIGURATION GUIDE V 11.1.X Specifications

General IconGeneral
BrandJuniper
ModelSYSTEM BASICS - CONFIGURATION GUIDE V 11.1.X
CategorySoftware
LanguageEnglish

Related product manuals