Article ID: 318402 - View products that this article applies to.
This article was previously published under Q318402
This article describes how to set the Component Object Model (COM) apartment type that a managed thread enters.
When you start a managed thread, by default the thread does not enter any COM apartments. The managed thread enters an apartment implicitly when the first COM call is made from the thread. By default, the managed thread enters a multithreaded apartment (MTA) for the process. After a managed thread enters a COM apartment, it cannot leave and enter another apartment. You can cause a managed thread to enter a single-threaded apartment (STA) by using one of the following methods:
For more information, see the following Microsoft Developer Network (MSDN) Web sites:
Contact us for more help
Connect with Answer Desk for expert help.