Hi All,
I use a FormView control with InsertItemTemplate and updateItemtemplate. In each ItemTemplate I would like using UpdatePanel with the same web control inside, but it returns me a compilation error. If I put an UpdatePanel in insert and not update it works.
Why can t I not put in the same UpdatePanel insertItemTemplate and updateItemTemplate?
For example, with this code the error is
BC30260: 'DropDownListC' is already declared
<asp:FormView ID="FormView1" runat="server" DataKeyNames="id" DataSourceID="Sqlsource"
DefaultMode="Insert">
<EditItemTemplate>
<asp:UpdatePanel ID="UpdatePanel_categories" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<DDCategories:DropDownCategories ID="BC30260: 'DropDownListCategorie' is already declared" runat="server" AjouterChoixVide="true"
SelectedValue='<%# Bind("s_id") %>' OnSelectedIndexChanged="DropDownListC_OnSelectedIndexChanged"
AutoPostBack="true" />
</ContentTemplate>
</asp:UpdatePanel>
</EditItemTemplate>
<InsertItemTemplate>
<asp:UpdatePanel ID="UpdatePanel_categories" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<DDCategories:DropDownCategories ID="DropDownListC" runat="server" AjouterChoixVide="true"
SelectedValue='<%# Bind("s_id") %>' OnSelectedIndexChanged="DropDownListC_OnSelectedIndexChanged"
AutoPostBack="true" />
</ContentTemplate>
</InsertItemTemplate>
</asp:FormView>
Thank for you answer
Shakta