Click here to Skip to main content
15,888,803 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

I have @Html.ActionLink(((object)item.EntityName).ToString().

How can I verify whether the Entity name is null or not.

I.e Action link text null verification.

Thanks in advance.
Pavan.
Posted
Updated 16-Nov-11 1:43am
v2

1 solution

Do you own extension ActionLinkIfNotNull. In that extension, you would simply return the original string if the string is not null (or empty) and an empty string other wise.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900