Esempio n. 1
0
        private void dgvCuentas_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (dgvCuentas.SelectedRows.Count == 1)
            {
                pCodigoCuenta = dgvCuentas.SelectedRows[0].Cells["CodigoPlanCuenta"].Value.ToString();
                _planCuentaID = dgvCuentas.SelectedRows[0].Cells["PlanCuentaId"].Value.ToString();

                iForm miInterfaz = this.Owner as iForm;
                if (miInterfaz != null)
                {
                    miInterfaz.cambiarTexto(pCodigoCuenta);
                }
            }
            this.Close();
        }
        private void dgvEmpresas_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (dgvEmpresas.SelectedRows.Count == 1)
            {
                pRUCEmpresa = dgvEmpresas.SelectedRows[0].Cells["ruc"].Value.ToString();
                _EmpresaID  = dgvEmpresas.SelectedRows[0].Cells["empresaid"].Value.ToString();

                iForm miInterfaz = this.Owner as iForm;
                if (miInterfaz != null)
                {
                    miInterfaz.cambiarTextoRUC(pRUCEmpresa);
                }
            }
            this.Close();
        }
Esempio n. 3
0
        private void btnSeleccionar_Click(object sender, EventArgs e)
        {
            if (dgvCuentas.SelectedRows.Count == 1)
            {
                pCodigoCuenta = dgvCuentas.SelectedRows[0].Cells["CodigoPlanCuenta"].Value.ToString();

                _planCuentaID = dgvCuentas.SelectedRows[0].Cells["PlanCuentaId"].Value.ToString();

                iForm miInterfaz = this.Owner as iForm;

                if (miInterfaz != null)
                {
                    miInterfaz.cambiarTexto(pCodigoCuenta);
                }
                //frmRegistroAsientos forma = (frmRegistroAsientos)this.Parent;
                //(frmRegistroAsientos)this.Parent.pCodigoCuenta = pCodigoCuenta;
            }
            cancelo_formulario = false;
            this.Close();
        }
Esempio n. 4
0
        /// <summary>
        /// The Method to update the form with the style manager style and it's controls.
        /// </summary>
        public void UpdateForm()
        {
            if (MetroForm == null)
            {
                return;
            }

            if (MetroForm is iForm && CustomTheme != null)
            {
                iForm form = (iForm)MetroForm;
                form.Style        = Style;
                form.ThemeAuthor  = ThemeAuthor;
                form.ThemeName    = ThemeName;
                form.StyleManager = this;
            }

            if (MetroForm.Controls.Count > 0)
            {
                UpdateControls(MetroForm.Controls);
            }

            MetroForm.Invalidate();
        }