G
Guest
I have gridview with a templatefield in which is a loginview. The loginview
displays a delete linkbutton for a specified group only. when a record is
delete the loginview displays the contents of the rolegroup, but the Eval
function in the loginview no longer works (it still works in the
itemtemplate, just not the loginview portion). Any text or non-databound
controls in the contenttemplate still render, but the Eval function doesn't
bind any data to controls. Here is the layout:
<asp:templatefield showheader="False">
<itemtemplate>
<asp:linkbutton id="LinkButton1" runat="server" commandname="Select"
text="View"></asp:linkbutton>
evalwillshowafter_<%# Eval("RecId", "{0}") %>
<asp:loginview id="LoginView1" runat="server">
<rolegroups>
<asp:rolegroup roles="WebApp-Admin">
<contenttemplate>
evalwillnotshowafterdelete_<%# Eval("GasOilNaphthaId") %>
<asp:linkbutton id="LinkButton2" runat="server"
causesvalidation="False" commandname="DeleteRec"></asp:linkbutton>
</contenttemplate>
</asp:rolegroup>
</rolegroups>
</asp:loginview>
</itemtemplate>
</asp:templatefield>
I handle in the codefile the record delete.
Thanks,
Phil
displays a delete linkbutton for a specified group only. when a record is
delete the loginview displays the contents of the rolegroup, but the Eval
function in the loginview no longer works (it still works in the
itemtemplate, just not the loginview portion). Any text or non-databound
controls in the contenttemplate still render, but the Eval function doesn't
bind any data to controls. Here is the layout:
<asp:templatefield showheader="False">
<itemtemplate>
<asp:linkbutton id="LinkButton1" runat="server" commandname="Select"
text="View"></asp:linkbutton>
evalwillshowafter_<%# Eval("RecId", "{0}") %>
<asp:loginview id="LoginView1" runat="server">
<rolegroups>
<asp:rolegroup roles="WebApp-Admin">
<contenttemplate>
evalwillnotshowafterdelete_<%# Eval("GasOilNaphthaId") %>
<asp:linkbutton id="LinkButton2" runat="server"
causesvalidation="False" commandname="DeleteRec"></asp:linkbutton>
</contenttemplate>
</asp:rolegroup>
</rolegroups>
</asp:loginview>
</itemtemplate>
</asp:templatefield>
I handle in the codefile the record delete.
Thanks,
Phil