Gents,
I have formview and around 10 dropdown lists when I place them into itemtemplate its populated fine but when I tried to add new record
or edit existing one it’s give me :Object reference not set to an instance of an object..
This is my code snippet:
<asp:FormView ID="Fmv_TeacherPage" runat="server" CssClass="style1" OnItemCommand="Fmv_TeacherPage_OnItemCommand">
<ItemTemplate>
<table id="tbl_ItemTemplate">
<tr>
<td>
TeacherName
</td>
<td>
<asp:Label ID="ItemTemplate_lbl_TeacherName" Text='<%# Eval("TeacherName") %>' runat="server"></asp:Label>
</td>
</tr>
<asp:LinkButton ID="lnkNew" Text="New" CommandName="ItemTemplate_New" runat="server" />
|<asp:LinkButton ID="lnkEdit" Text="Edit" CommandName="ItemTemplate_Edit" CausesValidation="false" runat="server" />
|<a ...
Go to the complete details ...