DeleteDocVersion

Deletes Document Version.

Public Function DeleteDocVersion(ByVal DocId As Long,

ByVal VersionNo As Single,  

ByVal DeleteOlder As String) As Long

 

Parameters  

In/out

Name

Data type

Description

In

DocumentId

Long

Document Index.

In

VersionNo

Single

Version Number.

In

DeleteOlder

String

DeleteOlder Option.

 

Description

This function is called from OmniDocs Desktop. It is used to delete the document versions.

 

Return value

Name

Description

NG_SUCCESS

In case of success

-1

Invalid cabinet name

-3

Cabinet not connected

-2

Invalid Operation in Read-Only Cabinet.

 

Example

Dim DocumentId                         As  long

Dim VersionNo                           As  long

Dim sDeleteOlder                       As  String

Dim lRetVal                               As  long

VersionNo = 1.1

DocumentId = 483

sDeleteOlder = “N”

lRetVal = gPanDb.DeleteDocVersion(DocumentId, VersionNo, sDeleteOlder)

If lRetVal <> NG_SUCCESS Then

        MsgBox gPandDb.ErrDescription, vbInformation

        Screen.MousePointer = vbNormal

        Exit Sub

Else

        MsgBox “Success” 

  End If