BUG: "Invalid procedure call or argument" error message when you add a member variable by using the Class View Wizard in Visual C++ .NET (822332)
The information in this article applies to:
- Microsoft Visual C++ .NET (2003)
- Microsoft Visual C++ .NET (2002)
SYMPTOMSWhen you use the Add Member Variable Wizard in Visual C++ .NET to add a variable to a Dialog control, you may receive the
following error messages: Error: Invalid procedure
call or argument Visual C++ .NET 2003 Internet Explorer script error An error has occurred in the script on this page.
Line: 480
Char: 4
Error: Invalid procedure call or argument
Code: 0
URL: file://C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\VCWizards\MemVariableWiz\HTML\1033\default.htm
Visual C++ .NET 2002 error An error has occurred in the script on this page.
Line: 480
Char: 4
Error: Invalid procedure call or argument
Code: 0
URL: file://C:\Program Files\Microsoft Visual Studio .NET\Vc7\VCWizards\MemVariableWiz\HTML\1033\default.htm
CAUSEThis is a bug in the automation code for the DialogID
property. Whenever any custom enum definitions appear before the AFX IDD enum
in the header file, the Add Member Variable Wizard cannot find the dialog resource ID in the first
enum definition in the Microsoft Foundation Class Library (MFC) CDialog class and an error message is
displayed.RESOLUTIONMove any custom enum definitions after the IDD enum so that the IDD
enum appears first in the file if you search from the top down. The following code example shows how to add the custom
enum definition after the IDD enum definitions: enum { IDD = IDD_TESTDLG_DIALOG };
enum cust_enum{}; // Put the custom enum definition here. STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
Modification Type: | Minor | Last Reviewed: | 12/29/2005 |
---|
Keywords: | kbpending kberrmsg kbDlg kbwizard kbide kbbug KB822332 kbAudDeveloper |
---|
|