CE 6.0 IHTMLDocument2 don't execute scripts
Hello,
I've got a program written in C++. It was working fine on former versions of Windows CE but now I've got a probleam that the the browser windows I'm using inside that application didn't execute any scripts anymore.
The strange thing is that if I load the url with the IE on that device all is working fine.
when the url is loaded I download the content into a screen:
Code:
if (dStreamMem != NULL)
{
GlobalFree(dStreamMem);
}
RELEASE(dStream);
//Create stream
dStreamMem = GlobalAlloc(GMEM_MOVEABLE | GMEM_NODISCARD,size - (content - dBuffer) + additionalHTMLLen);
BYTE* dStreamMemBuf = (BYTE*)GlobalLock(dStreamMem);
memcpy(dStreamMemBuf,content,size - (content - dBuffer));
GlobalUnlock(dStreamMem);
if (FAILED(CreateStreamOnHGlobal(dStreamMem,false,&dStream)))
{
LOGTAG(Error_Download_CreateStreamOnHGlobal_Failed);
}
then I load the stream in a different method and try to display it in the browser window of my application
Code:
IPersistStreamInit* persistStream = NULL;
//Get document object
if (FAILED(pBrowser->get_Document(&dDisp)))
{
LOGTAG(Error_ShowPage_pBrowser_get_Document_Failed);
goto CLEANUP;
}
if (FAILED(dDisp->QueryInterface(IID_IHTMLDocument2,(VOID**)&doc)))
{
LOGTAG(Error_ShowPage_dDisp_QueryInterface_Failed);
goto CLEANUP;
}
if (FAILED(doc->QueryInterface(IID_IPersistStreamInit,(void**)&persistStream)))
{
LOGTAG(Error_ShowPage_doc_QueryInterface_Failed);
goto CLEANUP;
}
if (FAILED(persistStream->Load(dStream)))
{
LOG('I', "Load Stream failed!\r\n");
LOGTAG(Error_ShowPage_persistStream_Load_Failed);
ret = FALSE;
goto CLEANUP;
}
The page is displayed in HTML without any errors (or at least it seems so) but when I press a button there nothing is happen.
Anyone an idea what could cause such a behaviour?