sagar patil

sagar patil

  • NA
  • 5
  • 651

how to bind to grid databses name?

Oct 7 2015 6:54 AM
private void ListDatabasesInServer()
{
this.cmbDbName.Items.Clear();
// Loop through the databases list
foreach (Database db in this.m_Server.Databases)
{
//We don't want to be adding the System databases to our list
//Check if database is system database
if (!db.IsSystemObject)
{
this.cmbDbName.Items.Add(db.Name); // Add database to combobox
}
}
this.cmbDbName.SelectedIndex = 0;
//We have the list now
}
 
 
as per above bold line, i get database names but  tables are not to bind datagridview any one give me solution.. 

Answers (5)