This may sound like a stupid question but when I drop controls on my web form from the toolbox, how to I position them where I want them? They appear to drop in some weird default position and I can see no way of moving them?
<asp:Button
style="position:absolute;"
ID="Button1"
runat="server"
Text="Button"
/>
then when you goback into design nmode you can drag the control about on the page - a better way is to use stylesheets.
This may sound like a stupid question but when I drop controls on my web form from the toolbox, how to I position them where I want them? They appear to drop in some weird default position and I can see no way of moving them?
To move controls anywhere in the Visual Studio Designer then follow these few steps below
*In Visual Studio, Switch to DESIGN VIEW
*Then Navigate to Layout TAB (a dropdown will show)
gazolba
Member
22 Points
35 Posts
How to position controls on a page?
Sep 05, 2008 03:03 PM|LINK
This may sound like a stupid question but when I drop controls on my web form from the toolbox, how to I position them where I want them? They appear to drop in some weird default position and I can see no way of moving them?
liammcmullen
Contributor
2051 Points
353 Posts
Re: How to position controls on a page?
Sep 05, 2008 03:16 PM|LINK
style
="position:absolute;"to the control:
eg
<asp:Button style="position:absolute;" ID="Button1" runat="server" Text="Button" /> then when you goback into design nmode you can drag the control about on the page - a better way is to use stylesheets.budugu
All-Star
41110 Points
6020 Posts
Re: How to position controls on a page?
Sep 05, 2008 03:38 PM|LINK
You can set all control position to absolute -- Using Format | Position menu in Visual studio 2008..
Check this link..
http://blogs.msdn.com/webdevtools/archive/2008/03/11/absolute-and-relative-positioning-in-visual-web-developer-2008-designer.aspx
"Don't be afraid to be wrong; otherwise you'll never be right."
vinz
All-Star
126956 Points
17922 Posts
MVP
Re: How to position controls on a page?
Sep 05, 2008 03:44 PM|LINK
To move controls anywhere in the Visual Studio Designer then follow these few steps below
*In Visual Studio, Switch to DESIGN VIEW
*Then Navigate to Layout TAB (a dropdown will show)
*Select Position
*Then Check Absolute
*You're done
That simple! HTH!
MessageBox Controls for WebForms | Blog | Twitter | Linkedin