Efe Onah Ojobo

Efe Onah Ojobo

  • NA
  • 32
  • 5.9k

c#

Jun 25 2015 9:22 AM
i use these code to check for if a combobox and textbox is empty.
 
 
if(string.IsNullorWhiteSpace(textBox1.Text) && string.IsNullorEmpty(cmbcreditUnit.Text))
 
 
and it trigger is line of code.
 
listBox1.Items.Add(ComboBox1.SelectedItem);
 
 
 
by saying
Value cannot be Null,
Parameter name item.

Answers (1)