Click here to Skip to main content
15,907,149 members

Comments by Member 15347263 (Top 3 by date)

Member 15347263 13-Oct-21 22:55pm View    
Hi there, im my grdiview i have the below



<asp:templatefield headertext="Daily Total (RM)" headerstyle-horizontalalign="Left" itemstyle-horizontalalign="Left">
<itemtemplate>
<%--<asp:textbox id="txtTotal" runat="server" text="<%# Eval("Total") %>" forecolor="Maroon">--%>
<asp:label id="lblTotal" runat="server" text="<%# Eval("Total") %>">


in my codebehind i have the below :

Label mytotsale = (Label)e.Row.FindControl("lblTotal");


mytotsale.Text is always giving me null value. Please advise.
Member 15347263 11-Oct-21 5:46am View    
Thank you so much, it is working
Member 15347263 11-Oct-21 5:01am View    
Thank you so much for the reply, when i use text box i cant calculate the total after quantity changes.