Пример #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            GestionNodo n = new GestionNodo();

            n.Text = "Alta de Enlace";
            n.tipo = "Enlace";
            n.raiz = nodo;

            n.Show();
            cambios = true;
        }
Пример #2
0
        private void dataGridView1_CellMouseDown(object sender, DataGridViewCellMouseEventArgs e)
        {
            if (e.RowIndex > -1 && e.Button == MouseButtons.Right)
            {
                //abrir ventana

                GestionNodo g = new GestionNodo();
                g.Text      = "Gestión de Nodo";
                g.existente = true;
                g.raiz      = nodo;


                string buscar = dataGridView1.Rows[e.RowIndex].Cells[0].Value.ToString();

                foreach (var item in nodo.Carpetas)
                {
                    if (item.Direccion == buscar)
                    {
                        g.anterior = (Nodo)item;
                    }
                }

                if (g.anterior == null)
                {
                    foreach (var item in nodo.Paginas)
                    {
                        if (item.Direccion == buscar)
                        {
                            g.anterior = (Nodo)item;
                        }
                    }
                }



                g.Show();
            }
        }