UpdateDoc method

Content Manager OnDemand converts the folder field value to an application group field and updates the data from the specified value in the database.

Method:
short UpdateDoc(
long * DocIndex,
char * pFieldName,
char * pValue )
Parameters
DocIndex
Specifies a zero-based relative document number within the document list of the active folder. This parameter is required.
pFieldName
Specifies the name of a folder field. This parameter is required.
pValue
Specifies the value to be stored in the specified folder field. This value is a character string which is converted to data of the field type (that is, integer, date, and so on).

Date fields must be provided in the format required for the field. For example, specifying 02/03/23 is invalid when February 3, 2023 is required.

This parameter is required.

Description
Content Manager OnDemand converts the folder field value to an application group field and updates the data from the specified value in the database.
Return Value
Refer to return codes.
See Also
GetNumFolderFields, GetFolderFieldName, and GetFolderFieldNames method

C/C++

The following example updates the Balance field of the first document within the document list of the active folder.
 CArsOle * pArsCtrl;
 short rc;

   .
   .

 rc = pArsCtrl->UpdateDoc( 0,
                          "Balance",
                          "123.45" );
 if ( rc != ARS_OLE_RC_SUCCESS )
    ERROR;

   .
   .

Visual Basic

 Dim rc As Integer

   .
   .

 rc = ArsOle.UpdateDoc ( 0,       _
                        "Balance", _
                        "123.45" )
 if rc <> ARS_OLE_RC_SUCCESS Then
    MsgBox "ERROR"
    End
 End If

   .
   .