Declare function nsfdbopen lib "nnotes.dll" (ByVal Pathname As String, RETDB AS Long) AS INTEGER
Declare function nsfdbclose lib "nnotes.dll" (Byval HDB As long) AS Integer
Declare Function FTDeleteIndex lib "nnotes.dll" (Byval HDB As long) AS Integer
Sub initialize
DIM BUFFERSTR AS STRING
DIM RETURNCODEL AS Long
DIM HDBL AS Long
DIM session as new notessession
'Open the database
Returncodel = nsfdbopen (session.currentDatabase.server "!!" session.currentDatabase.filepath, HDBL)
IF RETURNCODEL <> 0 THEN
Error 9999, "An Error Occurred in The Main Routine Calling The API Function NSFDBopen." & Chr $ (10) & Trim $ (Return Code Was "&" Str $ (Returncodel)) & "."
EXIT SUB
END IF
'Delete the index
ReturnCodel = ftdelteIndex (HDBL)
IF RETURNCODEL <> 0 THEN
Error 9999, "An Error Occurred In the Main Routine Calling The API Function FTDeleteIndex." & Chr $ (10) & Trim $ (Return Code Was "&" Str $ (Returncodel)) & "."
Call nsfdbclose (HDBL)
EXIT SUB
END IF
'Close the database
Returncodel = nsfdbclose (HDBL)
End Sub