I have a method that will receive a string, but before I can work with it, I have to convert it to int. Sometimes it can be null and I ha
string
int
null
Another solution is
int someValue = string.IsNullOrEmpty(value) ? 0 : int.Parse(value);