The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
I'd agree with Lopati - IsNullOrEmpty is a specific question (as is IsNullOrWhitespace) which specifies exactly what conditions it checks for: HasValue doesn't, it implies a degree of "valueness" which is not implicit to a string, but is added by context. HasValue could mean "has a valid numeric", "has a name and address" which "IsNullOrEmpty" doesn't - it's a basic generic check which prepares the way for more explicit "value" checking.
I'll stick with IsNullOrWhitespace myself!
Sent from my Amstrad PC 1640 Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
I think it mostly depends on how the string identifies itself at any given moment - this is for all the snowflakes out ther (you know who you are).
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
They are little deities and therefore can't fail at anything, so it must be your fault.
Did you ever see them get angry after doing something clumsy and then being laughed at? There are not so many animals that would be able to understand the meaning of laughter at all, much less the concept of Schadenfreude.
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
I'm stealing one of the comments from the page since the language used suits my mood currently.
Of all the things that didn't happen this didn't happen the most.
Pick a 'reality-show' - any of the bloody things. They're a more honest representation of what actually happened than this. The final direction that end of the roll of paper-towel points in dispels any remaining uncertainty.
Fun video though, but the Roomba didn't do this alone.