Scroll CDHtmlDialog
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7

Thread: Scroll CDHtmlDialog

  1. #1
    Join Date
    Nov 2003
    Location
    Bacau, Romania
    Posts
    474

    Scroll CDHtmlDialog

    I have a CDHtmlDialog dialog with a htm page in it. The page is taller than the dialog. How can I scroll the dialog to see the entire htm page? I've tried different ways but I can't seem to be able to get an working vertical scroll.
    B.A. (NKProds)

    Here is what I do: http://www.nkprods.com
    I couldn't have done it without your help. Thanks.

  2. #2
    Join Date
    Nov 2003
    Location
    Bacau, Romania
    Posts
    474
    I have a CDHtmlDialog dialog with a htm page in it. The page is taller than the dialog. How can I scroll the dialog to see the entire htm page? I've tried different ways but I can't seem to be able to get an working vertical scroll. How can this be done?
    B.A. (NKProds)

    Here is what I do: http://www.nkprods.com
    I couldn't have done it without your help. Thanks.

  3. #3
    Join Date
    Feb 2002
    Location
    Japanese
    Posts
    15

    Re: Scroll CDHtmlDialog

    In OnInitDialog, try to add SetHostFlags(DOCHOSTUIFLAG_NO3DBORDER);.

  4. #4
    Join Date
    Jul 2005
    Posts
    1

    Red face Re: Scroll CDHtmlDialog

    I can confirm that this solution works. Thank you!

  5. #5
    Join Date
    Feb 2009
    Location
    Portland, OR
    Posts
    1,488

    Re: Scroll CDHtmlDialog

    Quote Originally Posted by RoarS View Post
    I can confirm that this solution works. Thank you!
    No, it doesn't. You have to call it before CDHtmlDialog::OnInitDialog();
    Last edited by ahmd; October 17th, 2009 at 02:19 PM.

  6. #6
    Join Date
    Jul 2007
    Posts
    55

    Re: Scroll CDHtmlDialog

    No, It doesn't have to be before CDHtmlDialog::OnInitDialog();
    It works even if you call after this line.

  7. #7
    Join Date
    Apr 2013
    Posts
    1

    Re: Scroll CDHtmlDialog

    You would be better off using the following code in the OnInitDialog--since Microsoft may change the default flags in the future.

    m_dwHostFlags &= ~DOCHOSTUIFLAG_SCROLL_NO;

    or

    SetHostFlags(m_dwHostFlags & ~DOCHOSTUIFLAG_SCROLL_NO);


    By default, m_dwHostFlags = DOCHOSTUIFLAG_NO3DBORDER | DOCHOSTUIFLAG_SCROLL_NO;

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center