C# TransactionScope 使用

注意: Windows 服务中,开启Distributed Transaction Coordinator 服务。

 

                using (var scope = new TransactionScope())
                {
                    //1. .....

                    //2. .....

                    //3. ....

                    scope.Complete();
                }

 

posted @ 2016-06-16 15:16  Young汨  阅读(379)  评论(0编辑  收藏  举报