473,473 Members | 1,735 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Auto scaling of controls in a form (.Net 2008).

88 New Member
DESKTOP APPLICATION.

Hi, below is the problem briefed:
In my home form I have a splitcontainer and few buttons. When the buttons are clicked respective forms are opened in the splitcontainer. The splitcontainer is anchored- top, left, right, bottom so that when the home form is resized the splitcontainer resizes itself automatically. The controls within the other forms are also anchored properly to resize themselves accordingly. But the problem is when i open a form in the splitcontainer, even if I resize the home form, the controls in the form within the splitcontainer aren't resizing. The reason is when the home form is resized the splitcontainer is resizing itself accordingly but the form inside the splitcontainer isn't (as forms don't have anchor or dock properties so I couldn't set them). As a result though the controls in the sub form are anchored to resize themselves yet they aren't. How to solve it.

In short I want the form in the splitcontainer and all the controls in it to resize automatically when the home form/splitcontainer is resized. Regards.
Mar 30 '10 #1
1 1282
priyamtheone
88 New Member
Never mind! I missed a small property. When you call the subform in the splitcontainer of the main form just set the property Dock to Fill.

Expand|Select|Wrap|Line Numbers
  1. dim objFrmSubForm as New frmSubForm()
  2.     objFrmSubForm.Dock=DockStyle.Fill
  3.     objFrmSubForm.Show()
  4.     objFrmSubForm=Nothing
Regards.
Apr 15 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Scott Castillo | last post by:
Does anybody know how to auto-submit a form in PHP without Javascript? For instance, submit form variables to self, validate the data in PHP on same page, then, if no errors, auto-submit the data...
1
by: rich | last post by:
I am trying to determine the best way to code a page with auto scaling left/right margins as well as an auto scaling footer. Here is a basic diagram of what I am hoping to achieve:...
0
by: LR | last post by:
I'm having problem scaling controls on the form. I have a form where I'm adding my user control at design time. If I run at 96 dpi it looks fine, all the controls inside my user control are sized...
5
by: Psych971 | last post by:
Hi, I'm wondering how I can generate a postback using javascript on a page that does not have any controls with the auto-postback property set to true. I know I can just use the submit() function...
2
by: Reinier VDW | last post by:
Hi, I am using VB2005Express Beta2 (CTP Feb2005) which appears to have a new auto scaling engine. For that reason it does not accept i.e. the command Me.Scale(2). Where can I find some...
2
by: bsmith | last post by:
Having a little problem with a project my boss gave me. We have a web based hosting site that we have multiple databases that the users can connect to. Right now we have it set up that they can...
1
by: =?Utf-8?B?RnJlZEM=?= | last post by:
When I add controls to a pocket PC form at design time, all the scaling works fine. I see in the initialize code the use of AutoScaleDeminsions and AutoScaleMode. However, when I add a control...
10
by: laredotornado | last post by:
Hi, I'm using php 5. Does anyone have any code or a function that auto submits a form that contains a single INPUT, of type = file? Thanks, - Dave
1
by: sitingduck | last post by:
I used this code to pull info from the database and into the array. $stu_quary = "SELECT `uname` FROM `user` WHERE level = 'Normal' AND class = '".$_SESSION."'"; ...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
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
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...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.