Element 'ListItem' is not known element .... in my DropDownList
Hi
I added <asp:ListItem Value="">Make a selection</asp:ListItem> with AppendDataBoundItems="True" on Step 13 on P488. I got the message;
Element 'ListItem' is not known element ....
Can you tell me why I have this message? Thanks
Han
<asp:TemplateField HeaderText="GenreId" SortExpression="GenreId">
<EditItemTemplate>
<asp:DropDownList ID="ddlGenre" AppendDataBoundItems="True" runat="server" DataSourceID="GenreDataSource" DataTextField="Name" DataValueField="Id" SelectedValue='<%# Bind("GenreId") %>'></asp:DropDownList>
<asp:ListItem Value="">Make a selection</asp:ListItem>
</EditItemTemplate>
<InsertItemTemplate>
<asp:DropDownList ID="ddlGenre" AppendDataBoundItems="True" runat="server" DataSourceID="GenreDataSource" DataTextField="Name" DataValueField="Id" SelectedValue='<%# Bind("GenreId") %>'></asp:DropDownList>
<asp:ListItem Value="">Make a selection</asp:ListItem>
</InsertItemTemplate>
<ItemTemplate>
<asp:Label ID="Label4" runat="server" Text='<%# Bind("GenreId") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
|