ibm-information-center/dist/eclipse/plugins/i5OS.ic.rbam6_5.4.0.1/hdfcd.htm

97 lines
6.3 KiB
HTML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="task" />
<meta name="DC.Title" content="Define a command" />
<meta name="abstract" content="To create a command, you must first define the command through command definition statements." />
<meta name="description" content="To create a command, you must first define the command through command definition statements." />
<meta name="DC.subject" content="command, CL, defining, instructions, command, statements, CMD (Command) statement, Command (CMD) statement, Parameter (PARM) command definition statement, description, PARM (Parameter) command definition statement, Element (ELEM) statement, command definition, QUAL (Qualifier) statement, definition, Qualifier (QUAL) statement, PMTCTL (Prompt Control) command definition statement, DEP (Dependent) statement" />
<meta name="keywords" content="command, CL, defining, instructions, command, statements, CMD (Command) statement, Command (CMD) statement, Parameter (PARM) command definition statement, description, PARM (Parameter) command definition statement, Element (ELEM) statement, command definition, QUAL (Qualifier) statement, definition, Qualifier (QUAL) statement, PMTCTL (Prompt Control) command definition statement, DEP (Dependent) statement" />
<meta name="DC.Relation" scheme="URI" content="defcm.htm" />
<meta name="DC.Relation" scheme="URI" content="cmdst.htm" />
<meta name="DC.Relation" scheme="URI" content="defpr.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="hdfcd" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Define a command</title>
</head>
<body id="hdfcd"><a name="hdfcd"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Define a command</h1>
<div><p>To create a command, you must first define the command through
command definition statements. </p>
<div class="section"> <p>The general format of the command definition statements and a
summary of the coding rules follow.</p>
<dl><dt><strong>Statement</strong></dt>
<dd><strong>Coding Rules</strong></dd>
<dt class="dlterm">CMD</dt>
<dd>One and only one CMD statement must be used. The CMD statement can be
placed anywhere in the source file.</dd>
<dt class="dlterm">PARM</dt>
<dd>A maximum of 99 PARM statements is allowed. The order in which you enter
the PARM statements into the source file determines the order in which the
parameters are passed to the command processing program (CPP) and validity
checking program (VCP). One PARM statement is required for each parameter
that is to be passed to the command processing program. To specify a parameter
as a key parameter, you must specify KEYPARM(*YES) for the PARM statement.
The number of parameters coded with KEYPARM(*YES) should be limited to the
number needed to uniquely define the object to be changed. To use key parameters,
the prompt override program must be specified when creating the command. Key
parameters cannot be defined with PMTCTL(*PMTRQS) or PMTCTL(label).</dd>
<dt class="dlterm">ELEM</dt>
<dd>A maximum of 300 ELEM statements is allowed in one list. The order in
which you enter the ELEM statements into the source file determines the order
of the elements in the list. The first ELEM statement must have a statement
label that matches the statement label on the TYPE parameter on the PARM or
ELEM statement for the list.</dd>
<dt class="dlterm">QUAL</dt>
<dd>A maximum of 300 qualifiers is allowed for a qualified name. The order
in which you enter the QUAL statements into the source file determines the
order in which the qualifiers must be specified and the order in which they
are passed to the validity checking program and command processing program.</dd>
<dt class="dlterm">DEP</dt>
<dd>The DEP statement must be placed after all PARM statements it refers to.
Therefore, the DEP statements are normally placed near the end of the source
file.</dd>
<dt class="dlterm">PMTCTL</dt>
<dd>The PMTCTL statement must be placed after all PARM statements it refers
to. Therefore, the PMTCTL statements are normally placed at the end of the
source file.</dd>
</dl>
<p>At least one PARM statement must precede any ELEM or QUAL
statements in the source file. The source file in which you enter the command
definition statements is used by the CRTCMD command when you create a command.
Use WebSphere<sup>®</sup> Development
Studio (formerly known as ADTS for AS/400<sup>®</sup>) to enter statements into a source
file. For information on entering statements into a source file, see the <a href="../books/c0926050.pdf" target="_blank">ADTS for AS/400: Source
Entry Utility (SEU)</a><img src="wbpdf.gif" alt="Link to PDF" /> book.</p>
</div>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="cmdst.htm">Use the CMD statement</a></strong><br />
When you define a command, you must include one and only one CMD statement with your command definition statements.</li>
<li class="ulchildlink"><strong><a href="defpr.htm">Define parameters</a></strong><br />
To define a parameter, you must use the PARM statement.</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="defcm.htm" title="This describes how you can define and create your own commands.">Define commands</a></div>
</div>
</div>
</body>
</html>