Hi
I have a problem. I need to modify a document via Back-End, if it´s open in Edit Mode it´s not problem, because I have a LS code, it checks if if document is busy, here my code:
Dim posa1 As Integer
Dim posa2 As Integer
Dim vUserT As String
Dim m As String
If doc.LockHolders(0) <> “” Then
posa1 = Instr(doc.LockHolders(0),"=")
posa2 = Instr(doc.LockHolders(0),"/")
vUserT = Mid(doc.LockHolders(0),posa1 + 1, posa2 - posa1 - 1)
m = "Document is locked by " + vUserT + Chr(13)
m = m + "Please try again"
Messagebox m,0+16,"Error"
uidoc.Document.apDateSigned = ""
uidoc.Document.apSignedBy = ""
uidoc.Document.apStatus = ""
uidoc.Document.Save True, True
Continue = False
Exit Sub
End If
My problem is when a user keeps document open in Read Mode, because when it happen doc.LockHolders(0) is equal to “”. When I write in back end when document is open, a Conflict Error is sent. Allow document locking is enabled.
Some body can helpme with any idea how can I check if document is busy in Edit/Read mode?
Thanks a lot.