By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,686 Members | 1,603 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,686 IT Pros & Developers. It's quick & easy.

Change ClientSize need to change the Control Size?

P: n/a
It appears to me that if I change the Control's client size the controls
size does not change to agree with the new size.

Does it work like the VB6 ScaleWidth and ScaleHeight?
That is after I change the Clientsize does the display stay the same but the
number of units required to reference a given point changes?

Anyway, it appears to me that If I want to change to size of the control so
that the client size is some value, I need to take the size of borders etc
into acount and change the control's size (rather than changing the
control's clientsize directly). Is that true??

Thank in advance,
Cal
Nov 20 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Hi Cal,

It may depend on the control. I tried changing the ClientSize of a Form and
of a Button, and in both cases, the size changed to accomodate the new
ClientSize.

Craig,
VB .Net Team
--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).

--------------------
From: " active" <ac****@REMOVEa-znet.com>
Subject: Change ClientSize need to change the Control Size?
Date: Sun, 4 Jan 2004 22:07:47 -0500
Lines: 16
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <et*************@tk2msftngp13.phx.gbl>
Newsgroups: microsoft.public.dotnet.languages.vb
NNTP-Posting-Host: AC8DE753.ipt.aol.com 172.141.231.83
Path: cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!tk2msftngp13.
phx.gblXref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:169862
X-Tomcat-NG: microsoft.public.dotnet.languages.vb

It appears to me that if I change the Control's client size the controls
size does not change to agree with the new size.

Does it work like the VB6 ScaleWidth and ScaleHeight?
That is after I change the Clientsize does the display stay the same but thenumber of units required to reference a given point changes?

Anyway, it appears to me that If I want to change to size of the control so
that the client size is some value, I need to take the size of borders etc
into acount and change the control's size (rather than changing the
control's clientsize directly). Is that true??

Thank in advance,
Cal

Nov 20 '05 #2

P: n/a
Thanks, I think the problem related to the fact that I had anchor set to
"none"

I guess I thought that would let me change position and size but it appears
that even if anchored I can change position programmatically.
I'm not sure what "none" is suppose to do. Do you know?

Thanks again,
Cal
"Craig Vick [MSFT]" <cr*****@online.microsoft.com> wrote in message
news:CZ**************@cpmsftngxa07.phx.gbl...
Hi Cal,

It may depend on the control. I tried changing the ClientSize of a Form and of a Button, and in both cases, the size changed to accomodate the new
ClientSize.

Craig,
VB .Net Team
--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).

--------------------
From: " active" <ac****@REMOVEa-znet.com>
Subject: Change ClientSize need to change the Control Size?
Date: Sun, 4 Jan 2004 22:07:47 -0500
Lines: 16
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <et*************@tk2msftngp13.phx.gbl>
Newsgroups: microsoft.public.dotnet.languages.vb
NNTP-Posting-Host: AC8DE753.ipt.aol.com 172.141.231.83
Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!tk2msftngp13. phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:169862
X-Tomcat-NG: microsoft.public.dotnet.languages.vb

It appears to me that if I change the Control's client size the controls
size does not change to agree with the new size.

Does it work like the VB6 ScaleWidth and ScaleHeight?
That is after I change the Clientsize does the display stay the same but

the
number of units required to reference a given point changes?

Anyway, it appears to me that If I want to change to size of the control sothat the client size is some value, I need to take the size of borders etcinto acount and change the control's size (rather than changing the
control's clientsize directly). Is that true??

Thank in advance,
Cal


Nov 20 '05 #3

P: n/a
Hi Cal,

None should mean it's not anchored. In running some simple code with
buttons and labels, the anchoring doesn't affect the behavior. Are you
possibly setting the Dock property?

Craig VB.Net Team
--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).

--------------------
From: " active" <ac****@REMOVEa-znet.com>
References: <et*************@tk2msftngp13.phx.gbl> <CZ**************@cpmsftngxa07.phx.gbl>Subject: Re: Change ClientSize need to change the Control Size?
Date: Sat, 10 Jan 2004 19:30:44 -0500
Lines: 68
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <uJ**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.languages.vb
NNTP-Posting-Host: AC99C267.ipt.aol.com 172.153.194.103
Path: cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!cpmsftng xa09.phx.gbl!TK2MSFTNGP08.
phx.gbl!TK2MSFTNGP10.phx.gblXref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:171865
X-Tomcat-NG: microsoft.public.dotnet.languages.vb

Thanks, I think the problem related to the fact that I had anchor set to
"none"

I guess I thought that would let me change position and size but it appears
that even if anchored I can change position programmatically.
I'm not sure what "none" is suppose to do. Do you know?

Thanks again,
Cal
"Craig Vick [MSFT]" <cr*****@online.microsoft.com> wrote in message
news:CZ**************@cpmsftngxa07.phx.gbl...
Hi Cal,

It may depend on the control. I tried changing the ClientSize of a Form

and
of a Button, and in both cases, the size changed to accomodate the new
ClientSize.

Craig,
VB .Net Team
--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).

--------------------
>From: " active" <ac****@REMOVEa-znet.com>
>Subject: Change ClientSize need to change the Control Size?
>Date: Sun, 4 Jan 2004 22:07:47 -0500
>Lines: 16
>X-Priority: 3
>X-MSMail-Priority: Normal
>X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
>X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
>Message-ID: <et*************@tk2msftngp13.phx.gbl>
>Newsgroups: microsoft.public.dotnet.languages.vb
>NNTP-Posting-Host: AC8DE753.ipt.aol.com 172.141.231.83
>Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFT NGP08.phx.gbl!tk2msftngp13

Nov 20 '05 #4

P: n/a


"Craig Vick [MSFT]" <cr*****@online.microsoft.com> wrote in message
news:JN**************@cpmsftngxa07.phx.gbl...
Hi Cal,

None should mean it's not anchored. In running some simple code with
buttons and labels, the anchoring doesn't affect the behavior. Are you
possibly setting the Dock property?

No.
The problem went away when I fix the anchoring.
Craig VB.Net Team
--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).

--------------------
From: " active" <ac****@REMOVEa-znet.com>
References: <et*************@tk2msftngp13.phx.gbl> <CZ**************@cpmsftngxa07.phx.gbl>
Subject: Re: Change ClientSize need to change the Control Size?
Date: Sat, 10 Jan 2004 19:30:44 -0500
Lines: 68
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <uJ**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.languages.vb
NNTP-Posting-Host: AC99C267.ipt.aol.com 172.153.194.103
Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!cpmsftng xa09.phx.gbl!TK2MSFTNGP08. phx.gbl!TK2MSFTNGP10.phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:171865
X-Tomcat-NG: microsoft.public.dotnet.languages.vb

Thanks, I think the problem related to the fact that I had anchor set to
"none"

I guess I thought that would let me change position and size but it appearsthat even if anchored I can change position programmatically.
I'm not sure what "none" is suppose to do. Do you know?

Thanks again,
Cal
"Craig Vick [MSFT]" <cr*****@online.microsoft.com> wrote in message
news:CZ**************@cpmsftngxa07.phx.gbl...
Hi Cal,

It may depend on the control. I tried changing the ClientSize of a Form

and
of a Button, and in both cases, the size changed to accomodate the new
ClientSize.

Craig,
VB .Net Team
--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).

--------------------
>From: " active" <ac****@REMOVEa-znet.com>
>Subject: Change ClientSize need to change the Control Size?
>Date: Sun, 4 Jan 2004 22:07:47 -0500
>Lines: 16
>X-Priority: 3
>X-MSMail-Priority: Normal
>X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
>X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
>Message-ID: <et*************@tk2msftngp13.phx.gbl>
>Newsgroups: microsoft.public.dotnet.languages.vb
>NNTP-Posting-Host: AC8DE753.ipt.aol.com 172.141.231.83
>Path:


cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFT NGP08.phx.gbl!tk2msftngp13

Nov 20 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.