private void Form1_Load(object sender, System.EventArgs e) { GeneaManager = new MyGenealogie.CGeneaManager(@"N:\MyGenalogie"); this.LoadUserInfo(); View = new CView(this, this.MainToolTip, new System.EventHandler(GraphicObject_Click), new System.EventHandler(GraphicObject_DoubleClick), this.PersonContextMenu, GeneaManager.Persons); View.FileName = @"C:\DVT\MyGenalogie.db\CurrentView.View"; View.Load(); mnuViewRefresh_Click(null, null); }
private void mnuViewNew_Click(object sender, System.EventArgs e) { PersonSelectorForm f = new PersonSelectorForm(); CPerson p = f.OpenDialog(this.GeneaManager); if (p != null) { View = new CView(this, this.MainToolTip, new System.EventHandler(GraphicObject_Click), new System.EventHandler(GraphicObject_DoubleClick), this.PersonContextMenu, GeneaManager.Persons); View.FileName = @"C:\DVT\MyGenalogie.db\CurrentView.View"; View.Add(p, 0, 0); mnuViewRefresh_Click(null, null); } }