Hi all,

I am using the ?: operator to check if a number wasn't entered in a textbox. If nothing was enetered, I want to default it to "0". The reason is because I need to convert the value to a numeric value that will be stored in a database. Below is the code I am using.

Code:
string test =  this.rtxtProtqty.Text == null ? "0" : this.rtxtProtqty.Text;
Thanks in advance.