Wednesday, April 29, 2009

Condition in XPath & Eval C# asp.net for Gridview or Datalist

Here I have if else if else 2 conditions
<%
#XPath("price").ToString() != "" ? "Sales Price:"+XPath("price").ToString() : XPath("listprice").ToString() != "" ? "List Price"+XPath("listprice").ToString() : "Too Low"%>
1 condition:
<%#XPath("detailurl") != "0" ? XPath("detailurl") : "sss"%>
 

No comments: