I\'m sure I\'ve missed something here. With a certain project I need to check if a string is empty or null.
Is there an easier way of writing this?
i
If you are on .NET 4, you can use
if(string.IsNullOrWhiteSpace(myString)){ }
else:
if(string.IsNullOrEmpty(myString)){ }