I am attempting to show or not show some text on a web page based upon a row count in and MSSQL table. The SELECT statment returns some value where one column contains "DISPLAY" or not. This id the number of rows containing "DISPLAY" are zero I DO NOT wish to display the content.

SO what I cam up with is -

<asp:SqlDataSource id="SqlDataSource5" runat="server" ConnectionString="<%$ ConnectionStrings:xyzDB %>" SelectCommand="SELECT COUNT(xEmerStatus) FROM xyzTABLE WHERE xEmerStatus = 'DISPLAY'">

<aspataList id="DataList5" runat="server" DataSourceID="SqlDataSource5">
<asp:Label id="Column1Label" runat="server" Text='<%# Eval("Column1") %>' />

If DataBinder.Eval(Container.DataItem,"Column1") = 0 Then
display code here
End If


Thus the question is how can I change the returned value to an integer and "test" is againt the zero ?

MANY THANKS for your assiatance.