I´d like to have my application return instances of SQL Server 2008 R2 Developer/Express.
I´m using:
System.Data.DataTable lokalni_servery = Microsoft.SqlServer.Management.Smo.SmoApplication.EnumAvailableSqlServers();
foreach (System.Data.DataRow row in lokalni_servery.Rows)
{
local_servers.Items.Add(row["Server"].ToString());
}
On my friend´s notebook with SQL Server 2008 R2 express 32 bit, it doesn´t find anything, but on my notebook with SQL Server 2008 R2 Developer 64 bit, it finds it almost everytime. I need to be able to find this instance of SQL on both machines.
Does anybody know why the application is behaving like this?
Is there a way to alter the method allowing for both notebooks to find the instance?