CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 1999
    Posts
    34

    Sizing a listview control on a dialog bar

    I place a listview control on a dialog bar. I want the listview control sizing with the window. The codes are as following:

    m_wndDlgBar.SetWindowPos(NULL, 3, 3, cx - 6, cy - 15, SWP_NOZORDER);
    pListCtrl->SetWindowPos(NULL, 3, 3, cx - 30, cy - 30, SWP_NOZORDER);

    But in this way, the scroll bar of the listview control is disappear. Why? How to do it properly?



  2. #2
    Guest

    Re: Sizing a listview control on a dialog bar

    have a similar problem. I know the reason, but not the solution:
    SetWindowPos sets the position of the MAIN window (e.g. dialog) relative to screen coordinates,
    but the sub-window (listviewer a.o.) relative to the client area of the main window.
    The same problem applies when you use MoveWindow.
    I don't know how to retrieve the coordinates of a control relative to the client area.
    If you find it out, please send me a hint:
    [email protected]

    bye,
    tadek


Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured