DES |
Perform an interactive recipient lookup, showing XMMG
as the default for the NEXT recipient.
The user is prompted for a recipient, with XMMG as the next default recipient.
The prompting will continue until the user has finished entering recipients.
The recipients are placed in the array XMY. Unlike DEST^XMA21, the array XMY
is not killed upon entry to this API. (It is assumed that XMY already
contains some valid recipients.)
Compare to TOWHOM^XMXAPIU (DBIA 2774).
Usage: S XMDUZ=user's DUZ
S XMMG=next default recipient
S XMDF="" (if you don't want any addressing restrictions)
D DES^XMA21
I $D(XMOUT) the user aborted
|
VARIABLES |
TYPE |
VARIABLES DESCRIPTION |
XMDUZ |
Input |
DUZ of the user doing the addressing.
|
XMMG |
Used |
(optional) Name or DUZ of the NEXT default recipient
to present to the user. If not supplied, default is XMDUZ.
|
XMDF |
Used |
(optional) If $D(XMDF), then all addressing
restrictions are waived.
|
XMY |
Output |
Array of recipients chosen by the user. Any
recipients already in the array prior to the call will still be there after
the call.
XMY(addressee)=""
|
XMOUT |
Output |
If $D(XMOUT), then the user aborted addressing,
either by ^ or by time-out.
|
X |
Output |
If X="^", then the user aborted addressing, either by
^, or by time-out. Otherwise, X="".
Just ignore this variable and rely on checking XMOUT.
|
|
INST |
Perform a non-interactive recipient lookup.
The recipient (in X) is looked up. If the lookup is successful, the recipient
is placed in the array XMY. The array XMY is not killed upon entry to this
API.
Compare to TOWHOM^XMXAPI (DBIA 2729).
Usage: S XMDUZ=user's DUZ
S X=recipient
S XMDF="" (if you don't want any addressing restrictions)
S XMLOC="" (if you want any error to be written to the output device)
D INST^XMA21
If the call succeeds,
Y=addressee info
XMY(addressee)=""
XMMG=other addressee info
If the call fails,
Y=-1
XMMG=error message
|
VARIABLES |
TYPE |
VARIABLES DESCRIPTION |
XMDUZ |
Used |
(optional) DUZ of the user doing the addressing.
Default is DUZ.
|
X |
Input |
local or remote address
|
XMDF |
Used |
If $D(XMDF), all addressing restrictions are waived.
|
XMLOC |
Used |
If $D(XMLOC), any error (in XMMG) is written to the
output device.
|
XMY |
Output |
If lookup is successful, the addressee is placed in
array XMY. The array is not killed upon entry to this call, so anything
already in XMY prior to the call will still be there after the call.
XMY(addressee)=""
|
Y |
Output |
If the lookup is successful, Y is
for a local address: DUZ^full name
for a remote address: domain IEN^domain name
If the lookup fails, Y=-1.
|
XMMG |
Output |
If the lookup is successful, XMMG is
for a local address: ""
for a remote address: "via "_full domain name via which the message will be
routed.
If the lookup fails, XMMG contains an error message suitable for printing.
(If $D(XMLOC), it will be printed.)
|
|
WHO |
This entry point is identical to INST^XMA21.
|
|
DEST |
Perform an interactive recipient lookup, showing
XMDUN as the default for the FIRST recipient.
The user is prompted for a recipient, with XMDUN as the first default
recipient. The prompting will continue until the user has finished entering
recipients. The recipients are placed in the array XMY. Unlike DES^XMA21,
the array XMY is killed upon entry to this API.
Compare to TOWHOM^XMXAPIU (DBIA 2774).
Usage: S XMDUZ=user's DUZ
S XMDUN=first default recipient
S XMDF="" (if you don't want any addressing restrictions)
D DEST^XMA21
I $D(XMOUT) the user aborted
|
VARIABLES |
TYPE |
VARIABLES DESCRIPTION |
XMDUZ |
Input |
DUZ of the user doing the addressing.
|
XMDUN |
Used |
The name or DUZ of the first default recipient. If
not supplied, default is XMDUZ.
|
XMDF |
Used |
If $D(XMDF), then all addressing restrictions are
waived.
|
XMY |
Output |
Array of recipients chosen by the user. The array is
killed upon entry to the API, so any recipients already in the array prior to
the call are gone.
XMY(addressee)=""
|
XMOUT |
Output |
If $D(XMOUT), then the user aborted addressing,
either by ^ or by time-out.
|
X |
Output |
If X="^", then the user aborted addressing, either by
^, or by time-out. Otherwise, X="".
Just ignore this variable and rely on checking XMOUT.
|
|
CHK |
Check to see whether XMDUZ is a member of group Y.
Example:
>S Y=1,XMDUZ=4 D CHK^XMA21 W $T
0 (User is not a member.)
>S Y=2,XMDUZ=4 D CHK^XMA21 W $T
1 (User is a member.)
|
VARIABLES |
TYPE |
VARIABLES DESCRIPTION |
XMDUZ |
Input |
DUZ of the user whose group membership you wish to
check.
|
Y |
Input |
IEN of the mail group in the MAIL GROUP file (#3.8)
whose membership you wish to check.
|
$T |
Output |
If $T, then the user is a member; otherwise not.
|
|