Hi Again,
Here is the new code where I took out any reference to "flow layout" but it
still does the same thing!
Does anyone know of a workaround for this bug?
<body MS_POSITIONING="GridLayout">
<form id="Form1" method="post" runat="server">
<asp:textbox id="TextBox1" style="Z-INDEX: 101; LEFT: 256px; POSITION:
absolute; TOP: 168px"
runat="server"></asp:textbox><asp:button id="Button1" style="Z-INDEX:
102; LEFT: 416px; POSITION: absolute; TOP: 168px" runat="server"
Text="Insert"></asp:button><asp:label id="Label1" style="Z-INDEX: 103;
LEFT: 528px; POSITION: absolute; TOP: 136px" runat="server"
Width="152px"></asp:label>
<DIV style="DISPLAY: inline; Z-INDEX: 105; LEFT: 256px; WIDTH: 152px;
POSITION: absolute; TOP: 144px; HEIGHT: 16px"
ms_positioning="GridLayout">City</DIV>
<DIV style="DISPLAY: inline; Z-INDEX: 106; LEFT: 104px; WIDTH: 136px;
POSITION: absolute; TOP: 144px; HEIGHT: 19px"
ms_positioning="GridLayout">State</DIV>
<uc1:UC_states ms_positioning="GridLayout" style="Z-INDEX: 107; LEFT:
104px; POSITION: absolute; TOP: 168px"
id="UC_states1" runat="server"></uc1:UC_states>
</form>
</body>
and here is the code for the user control:
Codebehind="UC_states.ascx.vb" Inherits="WebApplication1.UC_states"
TargetSchema="http://schemas.microsoft.com/intellisense/ie5" %>
<asp:dropdownlist id=DD_STATES accessKey=S DataMember="USSTATES"
ms_positioning="GridLayout" DataSource="<%# TheStates1 %>" runat="server"
DataTextField="STATE" DataValueField="STATE_ABBREV" Width="128px"
BackColor="#C0FFFF" Font-Bold="True" style="POSITION: absolute">
</asp:dropdownlist>
I added the ms_positioning and a style tag to the control - still doesn't
work. Then I tried dropping the control inside a Grid Layout Panel - didn't
work either. By the way, I followed a Microsoft example EXACTLY and it does
not work!
Help!!!
Dave
Quote:> Hi all,
> I created some of my first user controls and they worked like a charm
except
> for one thing-
> they cannot be repositioned on the screen with the mouse and it sticks in
> the upper left hand corner.
> When more controls are added, they too stick to the upper left hand corner
> of the form!
> You can't move them at all. All other displayable items can be positioned
> with no problems (so it's not a global thing).
> I figured I could just go into the HTML and type in the X and Y positions
> directly like so:
> (the user control here is "uc_states")
> <body MS_POSITIONING="GridLayout">
> <form id="Form1" method="post" runat="server">
> <asp:textbox id="TextBox1" style="Z-INDEX: 101; LEFT: 256px; POSITION:
> absolute; TOP: 168px"
> runat="server"></asp:textbox><asp:button id="Button1" style="Z-INDEX:
> 102; LEFT: 416px; POSITION: absolute; TOP: 168px" runat="server"
> Text="Insert"></asp:button><asp:label id="Label1" style="Z-INDEX: 103;
> LEFT: 512px; POSITION: absolute; TOP: 232px" runat="server"
> Width="152px"></asp:label><uc1:uc_states id="UC_states1"
style="Z-INDEX:
> 104; LEFT: 104px; POSITION: absolute; TOP: 168px"
> runat="server"></uc1:uc_states>
> <DIV style="DISPLAY: inline; Z-INDEX: 105; LEFT: 256px; WIDTH: 152px;
> POSITION: absolute; TOP: 144px; HEIGHT: 16px"
> ms_positioning="FlowLayout">City</DIV>
> <DIV style="DISPLAY: inline; Z-INDEX: 106; LEFT: 104px; WIDTH: 136px;
> POSITION: absolute; TOP: 144px; HEIGHT: 19px"
> ms_positioning="FlowLayout">State</DIV>
> </form>
> </body>
> This works only in the editor. During runtime the user control jumps back
> up to the top left.
> Looks like a bug to me!
> VS.Net 2003 (VB.NET), FW1.1
> Any ideas?
> TIA
> Dave