Re: resize more than one control proportion
From: Peter Proost (pproost_at_nospam.hotmail.com)
Date: 10/26/04
- Next message: Joe Kaplan \(MVP - ADSI\): "Re: Authorization problem"
- Previous message: Derek Martin: "Re: Getting the user's DN"
- In reply to: DraguVaso: "resize more than one control proportion"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 26 Oct 2004 15:56:34 +0200
Hi Peiter,
create a new form, size=640;424, than place 2 datagrids on it, datagrid one
at the location 0;0 and size:632;200 and datagrid 2 at location 0;200 and
the same size, then copy paste the following code and see if this is what
you want:
<<<<<code>>>>>>>>
Private Sub Form1_Resize(ByVal sender As Object, ByVal e As
System.EventArgs) _ Handles MyBase.Resize
DataGrid1.Width = Me.Width - 8
DataGrid2.Width = Me.Width - 8
DataGrid2.Height = (Me.Height - 24) / 2
DataGrid1.Height = (Me.Height - 24) / 2
DataGrid2.Location = New Point(0, DataGrid1.Height)
End Sub
<<<<<code>>>>>
hth Peter
"DraguVaso" <pietercoucke@hotmail.com> wrote in message
news:#pFNTKzuEHA.3972@TK2MSFTNGP15.phx.gbl...
> Hi,
>
> I have to DataGrid's on a form, one on the top of my form, the other at
the
> bottom, but they though each other somewhere in the middle. What I want
now
> is that, when I resize the form, they resize in the same proportions: So
> when I resize the Form with 50%, they each have to resize with 50%.
>
> The maximum what I can achieve now is that one of them resizes, and the
> other keeps the same height, if I don't do it like that one of the
> DaatGrid's comes in front of the other.
>
> Any help would be really appreciated!
>
> Thansk a lot in advance,
>
> Pieter
>
>
- Next message: Joe Kaplan \(MVP - ADSI\): "Re: Authorization problem"
- Previous message: Derek Martin: "Re: Getting the user's DN"
- In reply to: DraguVaso: "resize more than one control proportion"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|