Results 1 to 5 of 5

Thread: [RESOLVED] property: control size changing according to forms size?

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2008
    Posts
    778

    Resolved [RESOLVED] property: control size changing according to forms size?

    Hello,
    I am after a property that makes a control (textbox, datagrid or other) move according to the forms size. Because some of the controls I got does that, and I really don't want it. I've been looking at them but could not find it.
    If somebody knows what property it is please post.

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,299

    Re: property: control size changing according to forms size?

    Take a look at the Anchor properties.

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2008
    Posts
    778

    Re: property: control size changing according to forms size?

    anchor set to none on some

    with my datagrid for example I got anchor set to top and left, if I set anchor to none it jumps down when I run it

    annoying me
    Last edited by MrtforCode; May 12th, 2009 at 04:24 AM.

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,299

    Re: property: control size changing according to forms size?

    You should pretty much always have a control anchored to at least one side. The default is Top and Left, so that means that the control will not move or resize as its container resizes. I suggest that you create a brand new project with one form and one Button on that form. Experiment with the Anchor set to different values and then run the project and resize the form to see what happens to the Button. It should be quite easy to see how Anchor works from that.

  5. #5

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2008
    Posts
    778

    Re: property: control size changing according to forms size?

    cheers, resolved

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width