Retrieve sqlserver instances Problem
-
I have two instance name for SqlServer. I write this code :
SqlDataSourceEnumerator sqlserver = SqlDataSourceEnumerator.Instance;
DataTable dt = sqlserver.GetDataSources();
GridView1.DataSource = dt;
GridView1.DataBind();but when i run it , i couldn't see the result! What Should i Do?
[]D @ []v[] []D @ []v[]
modified on Thursday, May 7, 2009 8:23 PM
-
I have two instance name for SqlServer. I write this code :
SqlDataSourceEnumerator sqlserver = SqlDataSourceEnumerator.Instance;
DataTable dt = sqlserver.GetDataSources();
GridView1.DataSource = dt;
GridView1.DataBind();but when i run it , i couldn't see the result! What Should i Do?
[]D @ []v[] []D @ []v[]
modified on Thursday, May 7, 2009 8:23 PM
pampam110 wrote:
but when i run it , i couldn't see the result! What Should i Do?
Did you debug your code? What dt returns ?
cheers, Abhijit CodeProject MVP Web Site:abhijitjana.net
-
pampam110 wrote:
but when i run it , i couldn't see the result! What Should i Do?
Did you debug your code? What dt returns ?
cheers, Abhijit CodeProject MVP Web Site:abhijitjana.net