M
Monty
I have an ASP.Net project I developed in VS2003 (ASP.Net 1.1) that works
fine, but when I convert it to VS2005 (ASP.Net 2.0) it's behavior seems to
change. I have the following datagrid in my project:
<asp:datagrid id="grid" runat="server" AutoGenerateColumns="False"
AllowSorting="False" DataKeyField="myID">
<Columns>
<asp:TemplateColumn HeaderText="Action">
<ItemTemplate>
'''''''NOTE FOLLOWING LINE:
<input Runat="server" ID="SelectedRequest" type="hidden"
NAME="SelectedRequest" />
'''''''NOTE PREVIOUS LINE ^
<asp:Literal Runat="server" ID="litRadioButtons" />
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="Action Message">
<ItemTemplate>
Message:<br>
<asp:TextBox ID="txtMessage" Runat="server" />
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:datagrid>
When I run this page in VS2003, the line noted above is rendered as:
<input name="grid:_ctl2:SelectedRequest" id="grid__ctl2_SelectedRequest"
type="hidden" />
But when I run my converted project in VS2005, it is rendered as:
<input name="SelectedRequest" type="hidden" id="SelectedRequest" />
What am I missing here? Why isn't the ID of my input control being modified
by it's naming container?
TIA.
fine, but when I convert it to VS2005 (ASP.Net 2.0) it's behavior seems to
change. I have the following datagrid in my project:
<asp:datagrid id="grid" runat="server" AutoGenerateColumns="False"
AllowSorting="False" DataKeyField="myID">
<Columns>
<asp:TemplateColumn HeaderText="Action">
<ItemTemplate>
'''''''NOTE FOLLOWING LINE:
<input Runat="server" ID="SelectedRequest" type="hidden"
NAME="SelectedRequest" />
'''''''NOTE PREVIOUS LINE ^
<asp:Literal Runat="server" ID="litRadioButtons" />
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="Action Message">
<ItemTemplate>
Message:<br>
<asp:TextBox ID="txtMessage" Runat="server" />
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
</asp:datagrid>
When I run this page in VS2003, the line noted above is rendered as:
<input name="grid:_ctl2:SelectedRequest" id="grid__ctl2_SelectedRequest"
type="hidden" />
But when I run my converted project in VS2005, it is rendered as:
<input name="SelectedRequest" type="hidden" id="SelectedRequest" />
What am I missing here? Why isn't the ID of my input control being modified
by it's naming container?
TIA.