Kofax DM API Manual do Utilizador Página 65

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 528
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 64
DM API OBJECTS 45
PCDASPFileUpload
PCDASPFileUpload is a helper class/interface/object that supports the
tying of the
POST of an ASP Multipart/Form file into a PCDPutStream.
(The
GET method is not supported in PCDPutStream, so always use
POST.) It handles all the parsing of headers from the body content and
streaming of the file that is to be uploaded into the DM PCDPutStream
object.
The OnStartPage method initializes the COM interface pointers to all
of the ASP objects, such as Session, Application, Request, Response,
and Server. These are passed by the ASP engine from the interface
pointer.
The Execute method reads from the ASP Request object that is
obtained during OnStartPage. It uses the
ReadBinary method to write
to the PCDPutStream object that the server supplies.
The IsEmpty method can be used to determine if the body of the
content is empty, which would indicate that a zero-byte file was sent.
IsEmpty looks at the posted stream, parses out the header, and
determines if the document being sent is empty. If the content is empty,
the success return value is set to
TRUE, and the error state is set to
PCD_ERR_ZERO_BYTE_UPLOAD. If the body content is not empty, the
success return value is set to
FALSE, and no error condition is set.
The OnEndPage method releases all the interface pointers acquired
during the OnStartPage initialization and resets the error state.
Example
The following is an example of creating an instance of the
PCDASPFileUpload.
.
.
.
Dim pFile As Object
.
.
.
pFile = _
Server.CreateObject("PCDClient.PCDASPFileUpload”
)
Vista de página 64
1 2 ... 60 61 62 63 64 65 66 67 68 69 70 ... 527 528

Comentários a estes Manuais

Sem comentários