public void AddTablesToComboBox() { foreach (DataRow table in Dbo.GetTablesFromSchema().Rows) { TreeNode node = new TreeNode(table.ItemArray[0].ToString()); foreach (DataColumn column in Dbo.GetWholeTable(table.ItemArray[0].ToString()).Columns) { node.Nodes.Add(column.ColumnName); } tablesTreeView.Nodes.Add(node); } }
private void ShowTable(string table) { grid.DataSource = Dbo.GetWholeTable(table); lastTableName = table; }