Using Forefront TMG 2000 and Forefront TMG COM Objects Together
Forefront TMG has administration COM objects that are not compatible with the ISA Server 2000 administration COM objects. Some of the Forefront TMG administration COM objects have the same names as ISA Server 2000 COM objects, but they have different class identifiers (CLSIDs). Attempting to use Forefront TMG and ISA Server 2000 COM objects with the same name in a single application can result in compilation errors due to name collisions.
If you need to build a single C++ application that supports using both the Forefront TMG administration COM objects and the ISA Server 2000 administration COM objects, you can avoid name collisions by using the rename_namespace attribute of the #import directive to rename the namespace of the Forefront TMG interfaces when you include the Microsoft Forefront Threat Management Gateway Administration Library (Msfpccom.dll) in your application.
By using the rename_namespace attribute, you can instruct Visual C++ to generate the classes declared in the Forefront TMG .idl file under a namespace that differs from the one specified in the library itself. This way, even if the names of ISA Server 2000 and Forefront TMG interfaces are the same, you can avoid the resulting name collisions.
The following code instructs Visual C++ to include the file Msfpccom.dll and to change the namespace for the Forefront TMG interfaces to FPCTMG:
#import "%SystemDrive%\Program Files\Microsoft ISA Server\msfpccom.dll" rename_namespace("FPCTMG")
Then when using Forefront TMG interfaces in your code, you will need to qualify them with FPCTMG.
Build date: 7/12/2010