views:

89

answers:

1

Hi, i have a dataview with:

<asp:BoundField DataField="AccontoAutorizzato" HeaderText="Acconto Aut." 
                        SortExpression="AccontoAutorizzato" dataformatstring="{0:C}"  />

is possible hide the values of each with a condition like

 Visible=<%# ((Int32)Eval("StatoID") < 2) %>

?

Thanks

+1  A: 

It's possible with following

<asp:TemplateField HeaderText="Acconto Aut." >
     <ItemTemplate>
          <asp:Label ID="lbl" runat="server" Text='<%# Bind"AccontoAutorizzato") %>'
                        Visible='<%# ((int)(Eval("StatoID")) < 2) %>' />
     </ItemTemplate>
</asp:TemplateField>
Saar