Home Forums SQL Server 2005 Data Corruption From vb.net how can I rollback transaction which I created deferent Sql Server Stored Procedure RE: From vb.net how can I rollback transaction which I created deferent Sql Server Stored Procedure

  • Mujeeb, go to VB.Net help and search on Ado.net Transactions and you will find a good explanation about SQL Server transactions. This link may work.

    ms-help://MS.VSCC.v80/MS.MSDN.v80/MS.NETDEV.v10.en/dnadonet/html/transact.htm

    I would not rewrite your procs as others have suggested, just use the SQLConnection object like this:

    connection.BeginTransaction()

    ' perform your inserts here

    connection.Commit()

    Be sure to use Try Catch blocks and test your rollback logic also.

    Good Luck


    Doug