Contents: | Main | Chapter | See Also: | Getting Started Manual | Advanced User Manual |
This entry point sets the security access codes for a file. The call allows developers to change only the File Security Codes at a target site without having to transport the entire file. The codes are stored in the following nodes:
^DIC(filenumber,0,"AUDIT") |
Audit Access |
^DIC(filenumber,0,"DD") |
Data Dictionary Access |
^DIC(filenumber,0,"DEL") |
Delete Access |
^DIC(filenumber,0,"LAYGO") |
LAYGO Access |
^DIC(filenumber,0,"RD") |
Read Access |
^DIC(filenumber,0,"WR") |
Write Access |
FILESEC^DDMOD(FILE,.SECURITY_CODES,MSG_ROOT)
FILE | (Required) File number. (Cannot be less than 2.) | ||||||||||||
SECURITY CODES | (Required) Array of new security access codes:
|
||||||||||||
MSG_ROOT |
(Optional) The root of an array into which error messages are returned. If this parameter is not included, errors are returned in the default array: ^TMP("DIERR",$J) |
None.
Example 1
In this example we are going to set all of the File Security Code nodes:
. . . .>D ^%G . . . . Global ^DIC(16028 DIC(16028 . . . . ^DIC(16028,0) = ZPATR FILE^16028 . . . . ^DIC(16028,0,"GL") = ^DIZ(16028, . . . . ^DIC(16028,"%",0) = ^1.005^^0 . . . . Global ^ . . . .>S SECURITY("DD")="@" . . . .>S SECURITY("RD")="" . . . .>S SECURITY("WR")="A" . . . .>S SECURITY("DEL")="@" . . . .>S SECURITY("LAYGO")="@" . . . .>S SECURITY("AUDIT")="@" . . . .>D FILESEC^DDMOD(16028,.SECURITY) . . . .>D ^%G . . . . Global ^DIC(16028 . . . . DIC(16028 . . . . ^DIC(16028,0) = ZPATR FILE^16028 . . . . ^DIC(16028,0,"AUDIT") = @ . . . . ^DIC(16028,0,"DD") = @ . . . . ^DIC(16028,0,"DEL") = @ . . . . ^DIC(16028,0,"GL") = ^DIZ(16028, . . . . ^DIC(16028,0,"LAYGO") = @ . . . . ^DIC(16028,0,"RD") = . . . . ^DIC(16028,0,"WR") = A . . . . ^DIC(16028,"%",0) = ^1.005^^0
Example 2
In this example, we are going to use the results from the previous example and change just the Write Access.
. . . . >S SECURITY("WR")="a" . . . . >D FILESEC^DDMOD(16028,.SECURITY) . . . . >D ^%G . . . . Global ^DIC(16028 DIC(16028 . . . . ^DIC(16028,0) = ZPATR FILE^16028 . . . . ^DIC(16028,0,"AUDIT") = @ . . . . ^DIC(16028,0,"DD") = @ . . . . ^DIC(16028,0,"DEL") = @ . . . . ^DIC(16028,0,"GL") = ^DIZ(16028, . . . . ^DIC(16028,0,"LAYGO") = @ . . . . ^DIC(16028,0,"RD") = . . . . ^DIC(16028,0,"WR") = a . . . . ^DIC(16028,"%",0) = ^1.005^^0 . . . . Global ^
401 | The file does not exist or the File Number that was passed was less than 2. |
Reviewed/Updated: March 10, 2007