private void button3_Click(object sender, EventArgs e) { string ultimaTela = (string)rowCurrent[col_ultima]; if (ultimaTela != null) { Console.WriteLine(); MyForm mf = (MyForm)Activator.CreateInstance(Type.GetType("Questionario." + ultimaTela, true)); goToForm(mf); } }
public void backToForm() { MyForm backkers = Pilhas.Pop(); this.lastID = (int)LastID(); backkers.lastID = lastID; initDB(); //My.rowCurrent = rowCurrent; Dictionary <string, object> row = new Dictionary <string, object>(); row[col_ultima] = this.Name; updateRow(row); this.Hide(); backkers.Show(); }
public void goToForm(MyForm mf) { if (this is Encerrado) { this.Dispose(); } this.lastID = (int)LastID(); mf.lastID = lastID; initDB(); //My.rowCurrent = rowCurrent; Dictionary <string, object> row = new Dictionary <string, object>(); if (!this.Name.Equals("Inicio", StringComparison.OrdinalIgnoreCase) || !this.Name.Equals("Encerrado", StringComparison.OrdinalIgnoreCase)) { row[col_ultima] = mf.Name; updateRow(row); } Pilhas.Push(this); this.Hide(); mf.Show(); }
public void goToForm(MyForm mf) { if (this is Encerrado) { this.Dispose(); } this.lastID = (int)LastID(); mf.lastID = lastID; initDB(); //My.rowCurrent = rowCurrent; Dictionary<string,object> row = new Dictionary<string,object>(); if (!this.Name.Equals("Inicio", StringComparison.OrdinalIgnoreCase) || !this.Name.Equals("Encerrado", StringComparison.OrdinalIgnoreCase)) { row[col_ultima] = mf.Name; updateRow(row); } Pilhas.Push(this); this.Hide(); mf.Show(); }