Resizable panels
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: Resizable panels

  1. #1
    Join Date
    Jan 2011
    Posts
    14

    Resizable panels

    I have a form with a richtext box and an webbrowser control side by side. The richtextbox is on the left, the webbrowser control is on the right. I want to be able to have the separator between the two controls be adjustable so that when I move it to the left, the width of the richtextbox gets smaller while the width of the webbrowser increases, and when I move it to the right the width of the richtextbox increases while the width of the webbrowser decreased.

    When I increase the form's height, I want both the control's width to increase in side in proportion as well.

    Any ideas on how to do something like this?

  2. #2
    Join Date
    Jun 2008
    Posts
    2,477

    Re: Resizable panels

    Have you looked at the Dock and Anchor properties? Also, the behavior you describe is a bit odd. Why would one control get smaller as you expand the size of the form? I can understand it staying the same size and another control growing, but don't you think that one control growing while another simultaneously shrinks is weird and unexpected behavior?

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