Easy question on a datagrid.
I have the following going across:
I would like to have this not going along the columns
but instead each line. along each line
UserID :
Store:
Password:
instead of having
UserID Store Password
I tried to enter <BR> between </asp:TemplateColumn>
<asp:TemplateColumn>
UserID Store Password
<asp:EditCommandColumn ButtonType="LinkButton" UpdateText="<img src=images/Ok.gif border=0 align=absmiddle alt='Save changes'>"
CancelText="<img src=images/Cancel.gif border=0 align=absmiddle alt='Cancel editing'>" EditText="<img src=images/icn_edit.gif border=0 align=absmiddle alt='Edit this item'>">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:EditCommandColumn>
<asp:TemplateColumn Visible="TRUE" HeaderText="UserID">
<ItemTemplate>
<asp:Label Text='<%# Convert.ToString(DataBinder.Eval(Container.DataIte m, "UserID")) %>' Runat="server" ID="lblUserID">
</asp:Label>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="Store">
<ItemTemplate>
<asp:Label Text='<%# Convert.ToString(DataBinder.Eval(Container.DataIte m, "STORENAME")) %>' Runat="server" ID="lblSTORE">
</asp:Label>
</ItemTemplate>
<FooterTemplate>
<asp:DropdownList id="insertStores" runat="server" DataSource='<%# BindStores() %>' DataValueField="StoreID" DataTextField="STORE">
</asp:DropdownList>
</FooterTemplate>
<EditItemTemplate>
<asp:dropdownList ID="ddlStores" DataSource='<%# BindStores() %>' selectedindex='<%# GetSelectedIndexStore(DataBinder.Eval(Container.Da taItem, "STORENAME").ToString())%>' runat="server" DataTextField="STORE" DataValueField="StoreID">
</asp:dropdownList>
</EditItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="User Name">
<ItemTemplate>
<asp:Label Text='<%# Convert.ToString(DataBinder.Eval(Container.DataIte m,"USERNAME")) %>' Runat="server" ID="lblUserName">
</asp:Label>
</ItemTemplate>
<FooterTemplate>
<asp:TextBox id="insertUserName" Width="120" runat="server"></asp:TextBox>
</FooterTemplate>
<EditItemTemplate>
<asp:TextBox Runat="server" ID="editUserName" Text = '<%# Convert.ToString(DataBinder.Eval(Container.DataIte m,"USERNAME")) %>' Width="150">
I would like to have this not going along the columns
but instead each line. along each line
user:
password:
instead of having
user password
I tried to enter <BR> between </asp:TemplateColumn>
<asp:TemplateColumn>
I don't have any resources on me. And I not have much internet access time. If someone can help me. Then that would be great.
Even give me a link or what have you.
I get the error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: Literal content ('</br>') is not allowed within a 'System.Web.UI.WebControls.DataGridColumnCollectio n'.
Source Error:
Knowledge is to be shared.
__________________
Knowledge is to be shared.
|