Z-FIL11A

This document covers the following topics:


Description

File a document into another folder or file.

This subprogram is the same as Z-FIL11X with the exception that you can specify additional parameters: File-with-originals and New-keywords-only.

You can file a document into folder Work or any user-defined folder. You cannot file a document into a system folder such as the Inbasket or Outbasket.

You cannot specify a TRS folder or a TRS document. To file a document into a TRS folder, you must use Z-TRS11.

When you specify File-with-originals, all previous replies to this document are also filed. Since replies with a date and time later than the document you are currently filing are not considered, it is recommended that you always file the most recent object. So that you can easily retrieve all objects that you file together, it is recommended that you specify the same keyword(s) for all objects.

If you want to rename the document without filing it into another folder or file, you must specify New-document-name without specifing New-folder or New-file. Renaming is not possible when File-with-originals is also specified.

When you file a document which is currently stored in the Inbasket file New, the corresponding address list is updated so that the reception status of the document indicates that it has been read.

Parameters

Parameter Format In Out Remarks
Return-code N2 O X Input -1: no ET.
Cabinet A8 R   The cabinet in which the document is to be filed.
Password A8 R   The password of the above cabinet.
Document-name A32 R*   The name of the document to be filed. Either Document-name or ISN, not both. You must not specify the name of a TRS document.
ISN P10 R* X The ISN of the document to be filed. Input: either ISN or Document-name, not both. You must not specify the ISN of a TRS document. You can invoke Z-DIS11X prior to this subprogram to obtain the ISN for the desired document.
New-folder A15 O   The name of the folder in which the document is to be stored.You must not specify a system folder (except Work) or TRS folder.
New-file A15 O   The name of a file within the above folder in which the document is to be stored.
New-document-name A32 O   If specified, the document is filed with a new name.
Keywords A15/1:6 O   Keywords are helpful when you search for an object. You can specify up to 6 keywords. A keyword must not contain an asterisk (*). When you specify at least one new keyword, all previously defined keywords are deleted. Thus, to retain the previously defined keywords you must specify them once more.
New-keywords-only A1 O   If specified, all documents are filed with the keywords specified with the Keywords parameter. If not specified, all documents are filed with the keywords that have previously been specified for them.
File-with-originals A1 O   If specified, all previous replies to this document are also filed in the folder that is specified with the New-folder parameter.

Return Codes

00 Success
02 Invalid cabinet name or - in batch mode only - locked cabinet
03 Password incorrect
04 ISN was not found
08 Supply either ISN or name, not both
09 ISN does not point to correct object
10 Function not valid for a system folder
51 Invalid name
52 Document with specified name already exists
53 Requested object does not exist
54 At least one keyword was invalid
55 Requested folder/file does not exist
56 Requested folder is a TRS folder
90 TRS document may not be filed into any other folder
91 Renaming is not possible when File-with-originals is specified

Subprograms

Z-120
Z-122
Z-123
Z-147
Z-150
Z-165
Z-175
Z-177
Z-190
Z-194
Z-197
Z-222
Z-223
Z-230
Z-400
Z-401
Z-1200&0

Example

DEFINE DATA
LOCAL
*
1 RETURN-CODE         (N2)
1 CABINET             (A8)
1 PASSWORD            (A8)
1 DOCUMENT-NAME       (A32)
1 ISN                 (P10)
1 NEW-FOLDER          (A15)
1 NEW-FILE            (A15)
1 NEW-DOCUMENT-NAME   (A32)
1 KEYWORDS            (A15/1:6)
1 NEW-KEYWORDS-ONLY   (A1)
1 FILE-WITH-ORIGINALS (A1)
*
END-DEFINE
*
MOVE 'Cabinet'   TO CABINET
MOVE 'Password'  TO PASSWORD
MOVE 'Doc-name1' TO DOCUMENT-NAME
MOVE 'Work'      TO NEW-FOLDER
MOVE 'Fwork1'    TO NEW-FILE
MOVE 'Key1'      TO KEYWORDS(1)
MOVE 'Key3'      TO KEYWORDS(3)
MOVE 'X'         TO NEW-KEYWORDS-ONLY
MOVE 'X'         TO FILE-WITH-ORIGINALS
*
CALLNAT 'Z-FIL11A'
  RETURN-CODE
  CABINET
  PASSWORD
  DOCUMENT-NAME
  ISN
  NEW-FOLDER
  NEW-FILE
  NEW-DOCUMENT-NAME
  KEYWORDS (*)
  NEW-KEYWORDS-ONLY
  FILE-WITH-ORIGINALS
*
WRITE
  '='  CABINET             /
  '='  PASSWORD            /
  '='  DOCUMENT-NAME       /
  '='  ISN                 /
  '='  NEW-FOLDER          /
  '='  NEW-FILE            /
  '='  NEW-DOCUMENT-NAME   /
  '='  KEYWORDS (*)        /
  '='  NEW-KEYWORDS-ONLY   /
  '='  FILE-WITH-ORIGINALS /
*
IF RETURN-CODE NE 0
  WRITE / 'Return code' RETURN-CODE
ELSE
  WRITE / 'Return status OK'
END-IF
*
END