Functionality This function module creates a physical document based on a specificdocument class. The document class of the new document is specified when the functionmodule is called. The document ID can be assigned as a DCE-compatibleGUID, or it can be automatically assigned by KPro. You can assign attributes to the new phyiscal document. If the documentclass contains mandatory attributes, the document can be created onlyif all mandatory attributes are specified on the interface or if theyare inherited from the document class attributes. Relationships to and from other documents can also be created alongwith the physical document. In particular, the relationship with theassociated logical document should be set at this point. The GUID of arelationship can also be pre-set to be DCE-compatible. If the relevantstructure field is not filled when the function module is created, KProassigns the GUID. The GUID is then returned. If a relationship cannotbe created for some reason (see SDOK_RELA_CREATE), the exceptionBAD_RELATION occurs. If the physical document is derived from another document, one of thefunction modules SDOK_PHIO_CREATE_WITH_MODEL, SDOK_PHIO_CREATE_AS_COPY,or SDOK_PHIO_CREATE_NEW_VERSION is used instead of SDOK_PHIO_CREATE. After SDOK_PHIO_CREATE has been successfully executed, the document hasthe status "initial". Notes The document class is optional here because no meaningful default classcan be specified for this function module. You must, however, specify adocument class. If you attempt to call this function module withoutspecifying a document class, an exception occurs. The document ID or relationship ID has no semantic content and isnormally assigned by KPro. It makes sense for the application to assignIDs only in situations where the application has already used an IDbefore the document was created in KPro. In such cases, you must ensurethat the ID is DCE-compatible and that it is transferred as a 32-digithex character string, to avoid clashes with existing KPro documents. Attribute entries generated by KPro are not contained as exportparameters in the table PROPERTIES. They must be read using"PropertiesGet". |