InvalidArgument=Value of '0' is not valid for 'SelectedIndex'. Parameter name: SelectedIndex

Problem is:

when you start application, you do not have items in cmbBrand, but cmbProduct fires SelectedIndexChanged.

Try this:

remove SelectedIndexChanged event initialization from Form1.Designer.cs. Try to find following line:

this.cmbProduct.SelectedIndexChanged += new System.EventHandler(this.cmbProduct_SelectedIndexChanged);

After that, when you populate DataSet with data from xml file, initialize SelectedIndexChanged event:

dsUpdate.ReadXml(@"...\..\stock.xml");
cmbProduct.DataSource = dsUpdate.Tables[0].DefaultView.ToTable(true, "productname");//.DefaultView;
cmbProduct.DisplayMember = "productname";
this.cmbProduct.SelectedIndexChanged += new System.EventHandler(this.cmbProduct_SelectedIndexChanged);
cmbProduct.SelectedIndex = 0;