protected void btnSaveProducts_Click(object sender, EventArgs e) { //divPleaseWait.Visible = true; if (cmbCategory.SelectedIndex > 1) { string codes = string.Empty; for (int i = 0; i < dgvProducts.Rows.Count; i++) if (((CheckBox)dgvProducts.Rows[i].FindControl("chkSave")).Checked) codes += ((Label)dgvProducts.Rows[i].FindControl("lblSupplierCode")).Text + ","; if (codes.Length > 0) { EweBL eweBL = new EweBL(); string subcategories = string.Empty; for (int i = 0; i < lstCategory.Items.Count; i++) subcategories += lstCategory.Items[i].Text + ","; string status = eweBL.parseProducts(cmbEweCategory.SelectedItem.Text, subcategories.Substring(0, subcategories.Length - 1).Split(','), true, true, cmbCategory.SelectedItem.Text, int.Parse(cmbCategory.SelectedValue), chkOverwrite.Checked, codes.Substring(0, codes.Length - 1).Split(','), chkActive.Checked, chkApproved.Checked); SetStatus(status, System.Drawing.Color.Green, true); } divPleaseWait.Style.Add("display", "none"); //divPleaseWait.Visible = false; } else SetStatus("Odaberite kategoriju", System.Drawing.Color.Red, true); }