Pcdputdoc, Pcdputdoc 97, Th the – Kofax DM API User Manual

Page 117: Obje

Advertising
background image

DM API O

BJECTS

97

PCDPutDoc

PCDPutDoc

PCDPutDoc allows you to obtain and manage a set of

PCDPutStream

object pointers that your customized client application can use to write
the physical files that make up one version of a DM document to the
appropriate DM repository.

Syntax

PCDPutDoc.

methodOrProperty

Usage

The particular document/version that is to be written is determined by
setting search criteria. Normally, this would be the document ID
number, the version ID number, and possibly the sub-version
identifier. The actual names of these properties is determined by how
they are identified on the search form, rather than the names of the SQL
database columns they reference.

Note: While the DM API allows you to change the name of fields on forms you
create (or modify), you should only do this when absolutely necessary. You
should never rename original fields on the standard forms that DM creates
when you initially install it.

Also, you must set the

NUM_COMPONENTS

property in the search

criteria. This tells the server how many component files will make up
the document version. The default is 1, but some applications (such as
some CAD/CAM files) are comprised of several component files.

After calling

Execute

, you can call

GetRowsFound

to return

NUM_COMPONENTS

. Use

NextRow

or

SetRow

to iterate through the rows

found. For each of the component files, use

GetPropertyValue

(“

CONTENT

”) to retrieve a

PCDPutStream

object

pointer to use to write the file.

Example

The following example shows how you can use the PCDPutDoc object
in your custom applications.

Private Sub cmdCreateDoc_Click()

Dim DocNumber As Long

Advertising