hi
i am working in speech recognition, for this i am using SR Engine of the microsoft, i add the engine in my program as activex component
there is no compile error in my program, but when i run my program
then when the function of the engine need to called then follwing error occurs: assertion failed!
void AFX_CDECL CWnd::InvokeHelper(DISPID dwDispID, WORD wFlags, VARTYPE vtRet, void* pvRet, const BYTE* pbParamInfo, ...)
{
ASSERT(m_pCtrlSite != NULL); // not an OLE control (not yet, at least)
if (m_pCtrlSite == NULL)
return;
va_list argList;
va_start(argList, pbParamInfo);
m_pCtrlSite->InvokeHelperV(dwDispID, wFlags, vtRet, pvRet, pbParamInfo,
argList);
va_end(argList);
}
& my code is as follows:
BOOL CDlg2::OnInitDialog()
{
CDialog::OnInitDialog();
MessageBox("This is shown by Tanay");
// TODO: Add extra initialization here
CDirectSR DirectSR1;
CString str ;//+="dfdfdf";
str +="<start>=move";
str +="\n";
str +="<start>=turn";
DirectSR1.GrammarFromString(str);
DirectSR1.Activate();
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
when the " DirectSR1.GrammarFromString(str);" &
" DirectSR1.Activate()"
need to call invokehelper, the insertion failed
can any body help me how to rescue from this problem
my e-mail address is:
[email protected]