S
shapper
Hello,
On an ASP.NET MVC View I am using the following:
<%=Html.TextBox("Title", Model.Post.Title != null ? Model.Post.Title :
String.Empty)%>
In general is there a difference between using "" or String.Empty?
For example using:
String a = Model.Post.Title != null ? Model.Post.Title : String.Empty;
Or
String b = Model.Post.Title != null ? Model.Post.Title : "";
If there is no difference what is more correct to use?
Thanks,
Miguel
On an ASP.NET MVC View I am using the following:
<%=Html.TextBox("Title", Model.Post.Title != null ? Model.Post.Title :
String.Empty)%>
In general is there a difference between using "" or String.Empty?
For example using:
String a = Model.Post.Title != null ? Model.Post.Title : String.Empty;
Or
String b = Model.Post.Title != null ? Model.Post.Title : "";
If there is no difference what is more correct to use?
Thanks,
Miguel