Ejemplo n.º 1
0
        /// <summary>
        /// Function to save values in accountGrroupTable
        /// </summary>

        public void SaveFunction()
        {
            try
            {
                AccountGroupInfo infoAccountGroup = new AccountGroupInfo();
                AccountGroupSP   spAccountGroup   = new AccountGroupSP();

                infoAccountGroup.AccountName     = txtAccountName.Text.Trim();
                infoAccountGroup.AccountGroup    = cmbAccountGroup.SelectedItem.ToString();
                infoAccountGroup.AccountSubGroup = txtAccountSubGroup.Text.Trim();
                infoAccountGroup.AccountCode     = txtAccountCode.Text.Trim();
                infoAccountGroup.Affects         = cmbAffects.SelectedItem.ToString();
                infoAccountGroup.IsDefault       = false;
                infoAccountGroup.Narration       = string.Empty;
                infoAccountGroup.Extra1          = string.Empty;
                infoAccountGroup.Extra2          = string.Empty;


                spAccountGroup.AccountGroupAdd(infoAccountGroup);
                Messages.SavedMessage();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }