Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Transaction in Process Class
Message
De
16/03/2016 17:28:00
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Titre:
Transaction in Process Class
Divers
Thread ID:
01633215
Message ID:
01633215
Vues:
43
I have a question about a process class in MM.NET. We are using the EntityFramework along with MM.NET in a process class. The process method is making changes to several tables. We want to wrap the changes in a transaction. The only way we can find to do this is something like this:
var biz1 = new somebizobject();
var biz2 = new someotherbizobject();
var transaction = biz1.ObjectContext.Connection.BeginTransaction()

…do something using the business objects…

if (success) transaction.Commit()
else transaction.Rollback()
On the BeginTransaction call we get an error message saying the connection is not open.

So how do we do this?
Thanks,
Dan Jurden
djurden@outlook.com
Répondre
Fil
Voir

Click here to load this message in the networking platform