Check string null in any better way C# -


a method accepts 7 string parameters, , need checked null basic way of them !string.isnullorwhitespace(param1) , likewise there better or smarter way ? also, may wrap parameters in object if helps !

you can pass string list , check this:

if(list.all(x=>string.isnullorwhitespace(x))) {  } 

Comments

Popular posts from this blog

python - TypeError: start must be a integer -

c# - DevExpress RepositoryItemComboBox BackColor property ignored -

django - Creating multiple model instances in DRF3 -