When DeliveryMethodComboBox has no selectedItem, the
Object reference not set to an instance of an object.
error appears.
what is the best way to solve this? In this example i've added a try and catch.
try
{
DeliveryMethodLabel2.Text = DeliveryMethodComboBox.SelectedItem.ToString();
}
catch
{
DeliveryMethodLabel2.Text = "";
}