Scroll webpage through buttons, CppWebBrowser |
尚未結案
|
bigjing
一般會員 發表:4 回覆:4 積分:1 註冊:2005-01-24 發送簡訊給我 |
Hi,
I am trying to use Cppwebbrowser to make a simple browser which can show webpages.
But in my case, I need to use two buttons, page up and page down, to control the
the scrolling function of the webpage.
How can I do this?
Thank you for help :) Best regards,
bigjing
|
bigjing
一般會員 發表:4 回覆:4 積分:1 註冊:2005-01-24 發送簡訊給我 |
THis can be done by below code: HWND WndChild;
WndChild = FindWindowEx(CppWebBrowser1->Handle, 0, NULL, NULL);
if (WndChild)
{
WndChild = FindWindowEx(WndChild, 0, NULL, NULL);
PostMessage(WndChild,WM_KEYDOWN,VK_PRIOR,0); // send page up message
}
There is no problem when I open a webpage
But when using it to open a PDF file, I couldn't
navigate the file with this code.
Could some one give me some help on this?
Thanks a lots
|
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |