I code therefore I am.

May 5, 2009 at 1:52pm
0 notes
Comments (View)
home

Tags:
CSharp  

Chain ?? Operators

You can use multiple ?? operators to chain multiple null comparisons:

string text = value1 ?? value2 ?? String.Empty;

blog comments powered by Disqus