private string ValidateLineControlles() { string ValidateMessage = string.Empty; if (DropDownItemName.SelectedIndex <= 0) { DropDownItemName.Focus(); return("Please select the Item Name."); } if (DropDownProductName.SelectedIndex <= 0) { DropDownProductName.Focus(); return("Please select the Product Name."); } if (DropDownBrandName.SelectedIndex <= 0) { DropDownBrandName.Focus(); return("Please select the Brand Name."); } if (DropDownColorName.SelectedIndex <= 0) { DropDownColorName.Focus(); return("Please select the Color"); } if (string.IsNullOrEmpty(TxtNoItems.Text.ToString())) { TxtNoItems.Focus(); return("Please enter the number of Items"); } if (DropDownUnit.SelectedIndex <= 0) { DropDownUnit.Focus(); return("Please select the Unit."); } if (string.IsNullOrEmpty(TxtPurchasePrice.Text.ToString())) { TxtPurchasePrice.Focus(); return("Please enter the purchase price"); } if (string.IsNullOrEmpty(TxtSalesPrice.Text.ToString())) { TxtSalesPrice.Focus(); return("Please enter the sales price"); } if (string.IsNullOrEmpty(TxtCgstPer.Text.ToString())) { TxtCgstPer.Focus(); return("Please enter the Cgst percentage"); } if (string.IsNullOrEmpty(TxtSgstPer.Text.ToString())) { TxtSgstPer.Focus(); return("Please enter the Sgst percentage"); } return(ValidateMessage); }
private string ValidateLineControlles() { string ValidateMessage = string.Empty; if (DropDownItemName.SelectedIndex <= 0) { DropDownItemName.Focus(); return("Please select the Item Name."); } if (DropDownProductName.SelectedIndex <= 0) { DropDownProductName.Focus(); return("Please select the Product Name."); } if (DropDownBrandName.SelectedIndex <= 0) { DropDownBrandName.Focus(); return("Please select the Brand Name."); } if (DropDownColorName.SelectedIndex <= 0) { DropDownColorName.Focus(); return("Please select the Color"); } if (string.IsNullOrEmpty(TxtNoOfItems.Text.ToString())) { TxtNoOfItems.Focus(); return("Please enter the number of Items"); } if (string.IsNullOrEmpty(TxtDiscountHeader.Text.ToString())) { TxtDiscountHeader.Focus(); return("Please enter the discount price"); } return(ValidateMessage); }