ASP.NET with C# and SQL SERVER , some vb.net . asp.net examples, asp.net codes, asp.net programs, c# code, sql server queries, important codes.
Saturday, 20 October 2012
Transaction Scope in asp.net c#
add ddl from dialog box on right click on bin ->add refrences
using System.Transactions;
TransactionOptions options = new TransactionOptions();
options.IsolationLevel = System.Transactions.IsolationLevel.RepeatableRead ;
options.Timeout = new TimeSpan(0, 5, 0);
using (TransactionScope transactionScope = new TransactionScope(TransactionScopeOption.Required, options))
{
DoWork();
transactionScope.Complete(); //Tell the transaction to commit
}
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment