INFO: XML Web Services and Apartment Objects (303375)



The information in this article applies to:

  • Microsoft Web Services (included with the .NET Framework) 1.0
  • Microsoft Enterprise Services (included with the .NET Framework) 1.0
  • Microsoft Visual Studio .NET (2002), Professional Edition

This article was previously published under Q303375

SUMMARY

This article describes how to call Apartment objects from XML Web services through the COM interoperability layer.

MORE INFORMATION

The following are supported methods for calling Apartment objects from XML Web services:
  • The Web service can call an Apartment object, such as Visual Basic 6.0, that is registered in a COM+ library application.

    Note the component must be marked as Synchronization="Required" (default) and must reside on a computer that is running Microsoft Windows 2000 Service Pack 2 or later.
  • The Web service can call an Apartment object that is registered in a COM+ server application that resides on a computer that is running Windows 2000 Service Pack 2 or later.

Notes

When you call Apartment objects from XML Web services, remember the following:
  • The ASPCOMPAT attribute is not supported. Because ASPCOMPAT is not supported, your Apartment object cannot require ASP intrinsics.
  • Although you can use other methods to call Apartment objects from XML Web services, and these methods may appear to function correctly, these methods are neither tested nor supported.
  • If you want to run your Web services in multi-threaded apartments (MTAs), calls to your Apartment object are made by a single-threaded apartment thread. COM+ creates the proxy and stub and also handles the marshalling from the MTA in which the Web service resides to the single-threaded apartment (STA) in which the Apartment object resides.

Modification Type:MajorLast Reviewed:9/24/2003
Keywords:kbinfo KB303375