J
JS
Hey all,
I have three panels that take up the full width of the form minus the
splitter docked to the left and they are all anchored.
Panel1 (top panel) has a button on it to allow the user to change the height
depending on the current height.
private void BtnExpand_Click(object sender, System.EventArgs e)
{
if(this.Panel1.Height == 220)
{
this.Panel1.Height = 35;
}
else
{
this.Panel1.Height = 220;
}
}
This code works works exactly like I want it to. The problem I'm having is,
getting panel2 (middle panel) to keep it's anchor with panel1. Another
problem with this is getting Panel3 (bottom panel) to resize and stay
anchored with panel2.
Summary:
If Panel1 is resized, move Panel2 just below Panel1 and resize Panel3 to
fit in the remaining area of the form.
I thought about docking Panel3 to the bottom for the resize, but that screws
up my splitter.
Any help would greatly be appreciated.
Thanks,
- JS -
I have three panels that take up the full width of the form minus the
splitter docked to the left and they are all anchored.
Panel1 (top panel) has a button on it to allow the user to change the height
depending on the current height.
private void BtnExpand_Click(object sender, System.EventArgs e)
{
if(this.Panel1.Height == 220)
{
this.Panel1.Height = 35;
}
else
{
this.Panel1.Height = 220;
}
}
This code works works exactly like I want it to. The problem I'm having is,
getting panel2 (middle panel) to keep it's anchor with panel1. Another
problem with this is getting Panel3 (bottom panel) to resize and stay
anchored with panel2.
Summary:
If Panel1 is resized, move Panel2 just below Panel1 and resize Panel3 to
fit in the remaining area of the form.
I thought about docking Panel3 to the bottom for the resize, but that screws
up my splitter.
Any help would greatly be appreciated.
Thanks,
- JS -