Google 网上论坛不再支持新的 Usenet 帖子或订阅项。历史内容仍可供查看。

UI proxy helper dll

已查看 25 次
跳至第一个未读帖子

Muku

未读,
2008年6月9日 11:48:042008/6/9
收件人
Can any one suggest me any example for using UI proxy helper dll..

Thanks in Advance

regards
Muku

Luca Calligaris

未读,
2008年6月10日 01:13:392008/6/10
收件人
There's no example, anyway it's quite simple:

You have to write a DLL which exports a function which complies with this
definition:

typedef BOOL (*PFN_UIENTRYPOINT)(
LPVOID lpInBuffer,
DWORD nInBufferSize,
LPVOID lpOutBuffer,
DWORD nOutBufferSize,
PDWORD pBytesReturned
);

For example, suppose you write kmsgbox.dll which exports the following:

extern "C" BOOL KMessageBox(
LPVOID lpInBuffer,
DWORD nInBufferSize,
LPVOID lpOutBuffer,
DWORD nOutBufferSize,
PDWORD pBytesReturned
)
{
return (BOOL)MessageBox(NULL,(LPCTSTR)lpInBuffer,_T("TEST"),MB_OK);
}

Then from kernel mode you can call:

CeCallUserProc(_T("kmsgbox.dll"),_T("KMessageBox"),...);

To show the Message Box;

Notice that, although the docs do not specify it:

* you can not pass a NULL lpInBuffer parameter to CeCallUserProc
** nInBufferSize parameter can not be greater than nOutBufferSize

--

Luca Calligaris
www.eurotech.it

"Muku" <mukes...@gmail.com> ha scritto nel messaggio
news:dd110f1b-d19f-478f...@s21g2000prm.googlegroups.com...

0 个新帖子