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

    resize grids with form help!

    Hi,
    I have a form with two grids one it. I would like to make it so when i resize the form, the grids resize as well....usually i would just anchor the grid but with the two next to each other this wont work when i resize horizontally....Can anyone help me out with some code.....it would be greatly appreciated!

  2. #2
    Join Date
    Jul 2008
    Location
    WV
    Posts
    5,362

    Re: resize grids with form help!

    You just need to place some code in the forms resize event that sets the size of your grids using the form size as one of the values in the calculation.

    For example
    Code:
    MyGrid.Width=(MyForm.Width/2)-30
    Always use [code][/code] tags when posting code.

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