Group: Forum Members
Posts: 28,
Visits: 70
|
Hi all,
Below is my code which fail to rollback. Please advice
Public Sub thread()
Dim locblock As New BOprdyrec
Dim lnnumber As Integer
lnnumber = 1
Try
MicroFour.StrataFrame.Business.BusinessLayer.TransactionBegin("", Data.IsolationLevel.ReadCommitted)
Do While lnnumber > 0
lnnumber = lnnumber + 1
locblock.Add()
locblock.cpdrrefdoc = lnnumber.ToString
locblock.Save()
Loop
MicroFour.StrataFrame.Business.BusinessLayer.TransactionCommit("")
Catch ex As Exception
MicroFour.StrataFrame.Business.BusinessLayer.TransactionRollback("")
End Try
End Sub
|