NTPGetFieldTypeFromDatabase

 

NTPGetFieldTypeFromDatabase ( <ReportName>, <ServerName>, <DatabaseName> <FieldNr>, <FieldTypeBuffer> ) -> <ErrorCode>

 

 

Description

 

Retrieves the "n-th" field type in a report definition. This function reads the field type from a report definition, which has been saved in a database. In order for the selected field type to be recorded, a buffer (<FieldTypeBuffer>) produced by Lotus Script must be passed to the command. If a field type is to be read from a report saved on the file system, use the function NTPGetFieldType instead.

 

 

Declaration for Lotus Script

 

Declare Function NTPGetFieldTypeFromDatabase Lib "NTP.DLL" ( ByVal ReportName As String, ByVal ServerName As String, ByVal DatabaseName As String, ByVal FieldNr As Long, FieldTypeBuffer As String ) As Long

 

 

Parameters

 

<ReportName> (STRING)

The name of the report in which a field type is to be retrieved.

 

<ServerName> (STRING)

The name of the server on which the database can be found. If an empty string is passed, the database is assumed to be local. The server name should be passed in the same style and fashion, in which the "NotesDatabase" class retrieves it.

 

<DatabaseName> (STRING)

The name of the database that contains the report layouts. The database name may contain sub-directories (e.g. "Demo\ntp.nsf") and must be a relative address to the Notes data directory.

 

<FieldNr> (LONG)

The number of the field of which the type is to be retrieved.

 

<FieldTypeBuffer> (STRING)

Buffer to accept the field type read. The buffer must be created by using Lotus Script (e.g. Buffer = Space ( 255 ) )

 

 

Return value

 

<ErrorCode> (LONG)

Number of the error encountered (0 = no error)