Dim sqlConn As New SqlConnection(Current.Application.Get("dbstring"))
........
sqlConn.Open()
Dim sqlTrans As SqlTransaction = sqlConn.BeginTransaction()
saveSupplierRecord(sqlTrans, ......
sqlTrans.Commit() || sqlTrans.Rollback()
-------------------------------------------------------
Function InsertTransaction(ByRef sqlTrans As SqlTransaction .....
Dim sqlConn As SqlConnection
sqlConn = sqlTrans.Connection
.......
End Function
No comments:
Post a Comment