Search code examples
c#transactionscopemsdtc

How can I configure MSDTC settings programmaticaly?


I had some errors by using TRANSACTION SCOPE due to wrong settings in MSDTC configurations, so i found the solution...

go to Control Panel > Administrative Tools > Component Services > expand Component Services > expand Computers > expand My Computer > expand Distributed Transaction Coordinator > Right Click in DTC Local > Properties > go to Security Tab.

Now set the things you need, in my case i checked these:

  • Network DTC Access | --> at Security Setting group
  • Allow Remote Clients | --> at Client and Administration group
  • Allow Inbound | --> at Transaction Manager Communication group
  • Allow Outbound | --> at Transaction Manager Communication group
  • No Authentication Required | --> at Transaction Manager Communication group

I want to do this programmatically using c#.

Do someone know how to figure this out


Solution

  • I found the solution in this link:

    http://www.codeproject.com/Articles/729805/MSDTC-Manager?msg=4765921#xx4765921xx

    i just made some changes, cause i dont need full features.

    Really works