GENERAL DESCRIPTION |
This DBIA allows Accounts Receivable to delete a mail
group.
The Accounts Receivable code will first look to see if the mail group exists
in file 3.8 by looking at the B cross reference on the NAME (.01) field. If
the mail group exists, the code will next loop the AD cross reference on the
MEMBER GROUP NAME sub-field (.01) of the MEMBER GROUPS field (11) in file 3.8.
If the mail group is a member of another mail group, the mail group will be
removed from the MEMBER GROUPS field using DIK. Finally, the mail group will
be removed using DIK. The following is an example of the code that deletes
the IRS mail group:
S RCMIRSDA=+$O(^XMB(3.8,"B","IRS",0))
I RCMIRSDA D
. ; check to see if IRS mail group is a member of another
. ; mail group. If so, delete it from the other mail group.
. S RCDA(1)=0 F S RCDA(1)=$O(^XMB(3.8,"AD",RCMIRSDA,RCDA(1)))
Q:'RCDA(1) D
. . S RCDA=0 F S RCDA=$O(^XMB(3.8,"AD",RCMIRSDA,RCDA(1),RCDA))
Q:'RCDA D
. . . S DA(1)=RCDA(1),DA=RCDA,DIK="^XMB(3.8,"_RCDA(1)_",5,"
. . . D ^DIK
. ;
. ; delete the mail group
. S DA=RCMIRSDA,DIK="^XMB(3.8,"
. D ^DIK
|