private void Accion(int naccion)
        {
            switch (naccion)
            {
                case 1:
                    u_n_opsel = 1;
                    U_RefrescaControles();
                    Blanquear();
                    var BL = new tb_60movientosdocBL();
                    var BE = new tb_60movimientosdoc();

                    BE.moduloid = VariablesPublicas.Moduloid;
                    BE.local = VariablesPublicas.Local;
                    BE.tipodoc = tipdoc;
                    BE.serdoc = serdoc;
                    BE.numdoc = numdoc;

                    txtcodigo.Text = BL.GetAll_MaxCodigo(VariablesPublicas.EmpresaID.ToString(), BE).Tables[0].Rows[0]["maximo_codigo"].ToString();

                    if (dgvfileatached.CurrentRow != null)
                    {
                        dgvfileatached.CurrentRow.Selected = false;
                    }
                    break;
                case 2:
                    POnedatos();
                    u_n_opsel = 2;
                    U_RefrescaControles();
                    dgvfileatached.CurrentRow.Selected = true;
                    break;
                case 3:
                    xnomcampo = "";
                    if (dgvfileatached.CurrentRow != null)
                    {
                        var BLIR = new tb_60movientosdocBL();
                        var BEIR = new tb_60movimientosdoc();
                        BEIR.items = dgvfileatached.Rows[dgvfileatached.CurrentRow.Index].Cells["item"].Value.ToString().Trim();
                        tmpcursor = BLIR.GetAll_CONSULTAIR(VariablesPublicas.EmpresaID, BEIR).Tables[0];
                        if (BLIR.Sql_Error.Length > 0)
                        {
                            xnomcampo = BLIR.Sql_Error;
                            Frm_Class.ShowError(BLIR.Sql_Error, this);
                        }
                        else
                        {
                            if (tmpcursor.Rows.Count == 0)
                            {
                            }
                            else
                            {
                                for (lc_cont = 0; lc_cont <= tmpcursor.Rows.Count - 1; lc_cont++)
                                {
                                    xnomcampo = xnomcampo + tmpcursor.Rows[lc_cont]["relacion"] + "\r";
                                    if (lc_cont + 1 == 10)
                                    {
                                        break;
                                    }
                                }
                            }
                        }
                    }
                    if (xnomcampo.Length == 0)
                    {
                        var message = "Desea Eliminar Registro  " + dgvfileatached.Rows[dgvfileatached.CurrentRow.Index].Cells["item"].Value.ToString().Trim() + "-" + dgvfileatached.Rows[dgvfileatached.CurrentRow.Index].Cells["docglosa"].Value.ToString().Trim() + " ...?";
                        var caption = "Mensaje del Sistema";
                        var buttons = MessageBoxButtons.YesNo;
                        DialogResult result;
                        result = MessageBox.Show(this, message, caption, buttons, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);
                        if (result == DialogResult.Yes)
                        {
                            var BLE = new tb_60movientosdocBL();
                            var BEE = new tb_60movimientosdoc();
                            BEE.items = dgvfileatached.Rows[dgvfileatached.CurrentRow.Index].Cells["item"].Value.ToString().Trim();
                            BEE.norden = 1;
                            BEE.ver_blanco = 0;
                            BEE.vista = 1;

                            BEE.moduloid = VariablesPublicas.Moduloid;
                            BEE.local = VariablesPublicas.Local;
                            BEE.tipodoc = tipdoc;
                            BEE.numdoc = numdoc;
                            BEE.serdoc = serdoc;

                            tmpcursor = BLE.GetAll(VariablesPublicas.EmpresaID, BEE).Tables[0];

                            if (BLE.Sql_Error.Length == 0)
                            {
                                if (BLE.Delete(VariablesPublicas.EmpresaID, BEE))
                                {
                                    for (lc_cont = 0; lc_cont <= Tabla.Rows.Count - 1; lc_cont++)
                                    {
                                        if (Tabla.Rows[lc_cont]["item"] == dgvfileatached.Rows[dgvfileatached.CurrentRow.Index].Cells["item"].Value)
                                        {
                                            Tabla.Rows[lc_cont].Delete();
                                            Tabla.AcceptChanges();
                                            break;
                                        }
                                    }
                                    dgvfileatached.Refresh();
                                }
                                else
                                {
                                    Frm_Class.ShowError(BLE.Sql_Error, this);
                                }
                            }
                            else
                            {
                                Frm_Class.ShowError(BLE.Sql_Error, this);
                            }
                        }
                    }
                    else
                    {
                        MessageBox.Show(xnomcampo, "IMPOSIBLE ELIMINAR DOCUMENTO");
                    }
                    break;
            }
        }