Reputation: 3976
I have this check in ListView
<%# Eval("Count") != null ? Eval("Count") : 0%>/<%# Eval("MaxRange")%>
now i want to change that if count is null then it should show nothing.
I tried this but no avail.
<%# Eval("Count") != null ? Eval("Count") + '/' + <%# Eval("MaxRange")%> : null %>
Please let me know how to do this.
Thanks.
Upvotes: 0
Views: 2385
Reputation: 1785
try this
<%# Eval("Count") != null ? Eval("Count") + '/' + Eval("MaxRange") : ""%>
I think this should work
Upvotes: 1
Reputation: 10767
<%# Eval("Count") != null ? Eval("Count") + '/' + <%# Eval("MaxRange")%> : String.Empty%>
Upvotes: 0
Reputation: 9309
try this
<%# Eval("Count") != null ? Eval("Count") + '/' + <%# Eval("MaxRange")%> : ""%>
Upvotes: 0