473,386 Members | 1,908 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,386 software developers and data experts.

Usercontrol size problem

In VS 2005 I'm trying to create a usercontrol, but I have some
problems with it right now I can't figure out how to fix. The size of
my usercontrol is "Size 574; 619" I have anchored all controls added
to the form, so I can resize it up and down, and not left and rigth.
My usercontrol is a usercontrol project. In my main program I just
drag and drop the control from the Toolbox, her the problems starts,
the size of all subcontrols changes (gets bigger) so the usercontrol
looks very weirder, now my first thought was, that the size was
different from my usercontrol project, but its not, it's the same, so
I copied all subcontrols size managing into a form load event on the
usrcontrol, that fixed the problem, but I can't imaging that's the way
to do this, dose someone have an idea here how I can fix this?

Here is a picture that show the real size of the control.
http://deltadk.dk/correct.JPG

Here is a picture that shows the usercontrol placed on the main
program,
http://deltadk.dk/weird.JPG

Sep 6 '06 #1
2 8918
I fixed this by creating a new form and copy all controls to the new
form. I still have no cluw why size got bigger but this fixed my
ptoblem for now
On Wed, 06 Sep 2006 17:32:44 +0200, Rene Sørensen <re**@deltadk.dk>
wrote:
>In VS 2005 I'm trying to create a usercontrol, but I have some
problems with it right now I can't figure out how to fix. The size of
my usercontrol is "Size 574; 619" I have anchored all controls added
to the form, so I can resize it up and down, and not left and rigth.
My usercontrol is a usercontrol project. In my main program I just
drag and drop the control from the Toolbox, her the problems starts,
the size of all subcontrols changes (gets bigger) so the usercontrol
looks very weirder, now my first thought was, that the size was
different from my usercontrol project, but its not, it's the same, so
I copied all subcontrols size managing into a form load event on the
usrcontrol, that fixed the problem, but I can't imaging that's the way
to do this, dose someone have an idea here how I can fix this?

Here is a picture that show the real size of the control.
http://deltadk.dk/correct.JPG

Here is a picture that shows the usercontrol placed on the main
program,
http://deltadk.dk/weird.JPG
Sep 6 '06 #2
I found the problem, it was a font issue on the main form, the fonts
on the main form was bigger than the fonts on the user control.
On Wed, 06 Sep 2006 17:32:44 +0200, Rene Sørensen <re**@deltadk.dk>
wrote:
>In VS 2005 I'm trying to create a usercontrol, but I have some
problems with it right now I can't figure out how to fix. The size of
my usercontrol is "Size 574; 619" I have anchored all controls added
to the form, so I can resize it up and down, and not left and rigth.
My usercontrol is a usercontrol project. In my main program I just
drag and drop the control from the Toolbox, her the problems starts,
the size of all subcontrols changes (gets bigger) so the usercontrol
looks very weirder, now my first thought was, that the size was
different from my usercontrol project, but its not, it's the same, so
I copied all subcontrols size managing into a form load event on the
usrcontrol, that fixed the problem, but I can't imaging that's the way
to do this, dose someone have an idea here how I can fix this?

Here is a picture that show the real size of the control.
http://deltadk.dk/correct.JPG

Here is a picture that shows the usercontrol placed on the main
program,
http://deltadk.dk/weird.JPG
Sep 7 '06 #3

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

Similar topics

9
by: Ed | last post by:
Is there any known issue with the use of "Scripting.FileSystemObject"? Here's a snippet of my code to obtain the filesize of a file Set fso = CreateObject("Scripting.FileSystemObject") Set...
3
by: CSS problem | last post by:
Hi, I'm having a problem with a CSS defined font size on www.casajac.org I have a few links to different language pages on the top right of the banner. ("English, Nederlands ...) I had the link...
6
by: Pierre-Benoit | last post by:
Hi there, I've a strange problem with ado.net and an Access db. I need to create a little C# app that take the content of "ole object" field and then save it into a file. The problem is that...
1
by: Ing. Rajesh Kumar | last post by:
I have a UserControl with a TextBox "TextBox_1" and a ReadOnly Property "myText" in it. I am using this in a file (no Code Behind) as follows : HTML: <My:Control ID="txtName" runat="server" /> VB:...
0
by: BluDog | last post by:
Hi I have a vustom usercontrol that reacts by changing the background color when it receivess focus. However if i subsequently add another control to the usercontrol, that child control receives...
4
by: Martijn Mulder | last post by:
I want my custom UserControl to size and resize with its parent, a Form. But when I use the code Size=Parent.ClientSize; in the constructor of myUserControl, Parent is null and the operation...
1
by: mAbZ | last post by:
I neeed to instantiate an UserControl in an aspx page like this: <MyNamespace:MyControl ID="ctrl1" runat="server" MyParent="<%# this %>" /> where "this" is the current aspx page and should be...
1
by: =?Utf-8?B?TmV3YnJv?= | last post by:
I have created a usercontrol consisted of a linkLabel and textBox. textBox visible set to false initially. When I click on linkLabel linkClicked event fired which set textBox visible to true. I...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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,...

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.