IsTransactionLoggingDisabled

IsTransactionLoggingDisabled

Messagepar Stephane Maillard » 02 Août 2005 à 13:32

[syntax="ls"]Const DBOPTION1_DISABLE_TXN_LOGGING = &H00002000&



Const wAPIModule = "NNOTES" ' Windows/32



Declare Private Function NSFDbOpen Lib wAPIModule Alias "NSFDbOpen" _

( Byval P As String, hDB As Long) As Integer

Declare Private Function NSFDbClose Lib wAPIModule Alias "NSFDbClose" _

( Byval hDB As Long) As Integer



Declare Function NSFDbGetOptionsExt Lib "NNOTES" Alias "NSFDbGetOptionsExt" _

( Byval hDB As Long, V As Long) As Integer



Declare Private Function OSPathNetConstruct Lib wAPIModule Alias "OSPathNetConstruct" _

( Byval zP As Long, Byval S As String, Byval F As String, Byval N As String) As Integer



Function IsTransactionLoggingDisabled(db As NotesDatabase) As Variant

p$ = Space(1024)

OSPathNetConstruct 0, db.Server, db.FilePath, p$



Dim hDB As Long

NSFDbOpen p$, hDB

If hDB = 0 Then Exit Function



Dim V(2) As Long

NSFDbGetOptionsExt hDB, V(0)

NSFDbClose hDB



IsTransactionLoggingDisabled = Not ((V(1) And DBOPTION1_DISABLE_TXN_LOGGING) = 0)

End Function[/syntax]
Cordialement

Stéphane Maillard
Avatar de l’utilisateur
Stephane Maillard
Lord of DominoArea
Lord of DominoArea
 
Message(s) : 8695
Inscrit(e) le : 16 Déc 2004 à 01:10
Localisation : Bretagne

Retour vers API

cron