Article ID: 184977 - Last Review: August 8, 2007 - Revision: 2.2 FIX: ScriptControl Reports Invalid Language for VBScript in MFCThis article was previously published under Q184977 On This PageSYMPTOMS
When hosting the ScriptControl object in a MFC application, you may receive
the following error:
The operation could not be completed because the script engine has not
been initialized to a valid language.
CAUSE
When hosted as a control (and not just as a simple automation object), the
ScriptControl object fails to initialize itself properly if the specified
language is VBScript.
RESOLUTION
Here are two workarounds:
Sample CodeSTATUSMicrosoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article. This bug was corrected in Microsoft Internet Explorer 5. MORE INFORMATIONSteps to Reproduce Behavior
REFERENCES
For additional information, please see the following
article(s) in the Microsoft Knowledge Base:
184904
(http://support.microsoft.com/kb/184904/EN-US/
)
FILE: MSSCPCTL.EXE Script Control Header File MSSCPCTL.H
For additional information, please see the following World Wide Web URL:
http://msdn2.microsoft.com/en-us/library/ms950396.aspx
(http://msdn2.microsoft.com/en-us/library/ms950396.aspx)
APPLIES TO
| Article Translations
|

Back to the top
