It is a common workflow for Visual C++ developers to generate wrapper classes for ActiveX controls, which makes it easier to access controls instead of working with the controls directly. The steps to create these wrapper classes are as follows:Create a new dialog-based MFC application in Visual Studio 2008. This brings up the designer view of the form. Now add an ActiveX Control by right-clicking on the form and selecting 'Insert ActiveX Control...' Select any control and click OK. Once the control has been added to the form, right-click the control and select 'Add Variable...' This brings up the 'Add Member Variable Wizard' that generates the wrapper classes.
When following this workflow with an ArcGIS Engine 10.0 control the following error occurs."A Runtime error has occurred.
Do you wish to Debug?Line: 1211
Error: The Extender Provider failed to return an Extender for this object."
This is a bug with Visual Studio 2008; this problem has been reported to Microsoft. The problem is fixed in Visual Studio 2010.
▪ Generate the wrapper classes using a 9.3.1 control. Since the bug is specific to how the wrapper classes are generated, previously created wrappers will work correctly.
▪ Instead of using the wrapper classes, access the control directly. See the following code example:
CWnd* WndPageLayoutControl = GetDlgItem(IDC_PAGELAYOUTCONTROL3);
▪ This issue has been fixed in Visual Studio 2010; upgrade to Visual Studio 2010.
Get help from ArcGIS experts
Download the Esri Support App