473,408 Members | 1,861 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Filling resized panel with form

If I have a panel in which I have placed a maximised form, what's the
easiest way to resize the form to automatically fill the panel when the
panel is resized? I am using VS 2003.
--
Cheers, ymt.
Apr 10 '06 #1
3 2034
Yuk,
If I have a panel in which I have placed a maximised form, what's the
easiest way to resize the form to automatically fill the panel when the
panel is resized? I am using VS 2003.

The easiest is the Dock property in every control (in this case use it with
your panel), the second one is the anchor property.

I hope this helps,

Cor
Apr 11 '06 #2
"Cor Ligthert [MVP]" <no************@planet.nl> wrote in
news:eg**************@TK2MSFTNGP03.phx.gbl:

Yuk,
If I have a panel in which I have placed a maximised form, what's
the easiest way to resize the form to automatically fill the
panel when the panel is resized? I am using VS 2003.

The easiest is the Dock property in every control (in this case
use it with your panel), the second one is the anchor property.

I hope this helps,


Still no joy unfortunately. I've tried docking fill, top, left,
bottom, right, anchoring anywhere from here to Timbuktoo, but the
form still gets left behind when the panel is resized. I would try
playing around with the windowstate property, but it seems to forget
that panel.controls.item(x) is a form once I've exited the procedure
that called it into being and added it to the panel controls
collection, even with option strict on.

One interim solution I'm considering is to stop resizing, which
rather defeats the point of having a frame-based layout.
--
Cheers, ymt.
Apr 13 '06 #3
Yuk,

If you have let say placed your panel on another panel which is not docked,
than you have the behaviour as you tell.

While when you are docking you should not use the anchor and visa versa.

I hope this helps,

Cor

"Yuk Tang" <sa********************@bignet.com.au> schreef in bericht
news:Xn*******************************@130.133.1.4 ...
"Cor Ligthert [MVP]" <no************@planet.nl> wrote in
news:eg**************@TK2MSFTNGP03.phx.gbl:

Yuk,
If I have a panel in which I have placed a maximised form, what's
the easiest way to resize the form to automatically fill the
panel when the panel is resized? I am using VS 2003.

The easiest is the Dock property in every control (in this case
use it with your panel), the second one is the anchor property.

I hope this helps,


Still no joy unfortunately. I've tried docking fill, top, left,
bottom, right, anchoring anywhere from here to Timbuktoo, but the
form still gets left behind when the panel is resized. I would try
playing around with the windowstate property, but it seems to forget
that panel.controls.item(x) is a form once I've exited the procedure
that called it into being and added it to the panel controls
collection, even with option strict on.

One interim solution I'm considering is to stop resizing, which
rather defeats the point of having a frame-based layout.
--
Cheers, ymt.

Apr 13 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Robert Skidmore | last post by:
I am building an application that will fade one panel to another panel. Both panels will have picture boxes in them (thumbnails). This is what I have tried: private void...
2
by: hennakapoor | last post by:
How do the form filling software determine which text field gets what data i.e. a typical form filling software will ask the user to enter the username / address / password etc. Whenever it goes to...
1
by: Jay | last post by:
I need to be able to move a Panel on a windows Form at run time using the mouse. I have tried adding a MouseDown event handler to the Panel and then within the MouseDown handler adding a MouseMove...
5
by: Ron Vecchi | last post by:
I know the math I need to perform on width and height to keep an aspect ratio but where and how would I implement keeping a set aspect ratio on a form when a user resizes it. Override OnResize?...
3
by: Harry | last post by:
Hi, Can anyone help. I have a asp.net page (c#), with two panels, both of which have asp:textboxes on. When I press the first button, the second panel shows fine. When I press the button in...
2
by: Earl Teigrob | last post by:
I have written a photo app that allows the administrator to resize photos in an admin panel above the photo on the page. When the the new size is entered, the data is saved into a datastore and the...
2
by: Dan | last post by:
Hello, I am just now converting from the world of DOS. Making simple VB.NET apps was easier than I expected. Now I need some control over the window that the app is running in. Can a VB.NET...
2
by: Peteroid | last post by:
When the application I'm working on is run it creates a panel with a Paint event customized to draw primitives (circles, rectangles, etc.), places the panel on a form, and then launches the form....
8
by: =?Utf-8?B?R3JlZyBMYXJzZW4=?= | last post by:
I'm trying to figure out how to modify a panel (panel1) from a backgroundworker thread. But can't get the panel to show the new controls added by the backgroundwork task. Here is my code. In...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.