N2PDFAddRTContent

Start page  Previous page  Next page

 

N2PDFAddRTContent ( <JobID>, <ContentType>, <ContentOption>, <ServerName>, <DatabaseName>, <UNID>, <ItemName> ) -> <ErrorCode>

 

Description

This function is used to add a formatted text (RTF text) to the PDF file. The RTF text can be taken from one individual field within a Notes document or you can apply the entire Notes document.

 

The RTF text is added into the PDF file in the current insertion point, including all the formatting. When you invoke this function you can also choose the area of the PDF file (header, footer or main text) where the content is to be inserted.

 

When you invoke the function you reference the Notes RichText field or the Notes document entirely through the information "ServerName", "DatabaseName" and "UniversalID". n2pdf comes with its own RTF export filter and needs this information for directly referencing the RichText content.

 

Declaration for LotusScript

Declare Function N2PDFAddRTContent Lib LibName_

( ByVal JobID As Long, ByVal ContentType As Long,_

ByVal ContentOption As Long, ByVal ServerName As Unicode String,_

ByVal DatabaseName As Unicode String, ByVal UNID As Unicode String,_

ByVal  ItemName As Unicode String ) As Long

 

Parameters

<JobID> (LONG)

The number that is returned when N2PDFInit is invoked and which references the PDF file in the memory. You use this ID to control which PDF you want to access with the function.

 

<ContentType> (LONG)

This parameter is the same as the description of N2PDFAddContent.

 

<ContentOption> (LONG)

This parameter is the same as the description of N2PDFAddContent.

 

<ServerName> (UNICODE STRING)

This is the name of the server on which the database containing the RichText field or the Notes document is located. If this is a local database (from the perspective of the client or the server), then please enter "" as the value.

 

<DatabaseName> (UNICODE STRING)

This is the name of the database in which the RichText field or Notes document is located. Please keep in mind that under certain circumstances this name must also include a path if the database is found in a subdirectory of the Notes data directory. The path, however, must not be an absolute path ("C:\Notes\Data\N2PDF\Test.nsf") but always only be described as a path relative to the data directory of the client or the server ("N2PDF\Test.nsf").

 

<UNID> (UNICODE STRING)

This is the "Universal Document ID" of the RichText field or the Notes document that you want to add to the PDF file.

 

<ItemName> (UNICODE STRING)

If you want to transfer the content of a RichText field to the PDF file, then enter the name of the field in the Notes form. Should you want to export an entire Notes document, simply enter "" as the value here.

 

Return

<ErrorCode> (LONG)

The code number of the error that has occurred when performing the function (see "Error Codes ").