SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


accessing named instances


accessing named instances

Author
Message
shital.p
shital.p
SSC Rookie
SSC Rookie (48 reputation)SSC Rookie (48 reputation)SSC Rookie (48 reputation)SSC Rookie (48 reputation)SSC Rookie (48 reputation)SSC Rookie (48 reputation)SSC Rookie (48 reputation)SSC Rookie (48 reputation)

Group: General Forum Members
Points: 48 Visits: 10
accessing named instances
--------------------------------------------------------------------------------
hello
I installed two named insances of SQL Server 2005 on Win 2003 server.
I hv written small appl which list out all the insances of SQL Server available on network .
but it is not working , it is displaying only names of SQL Server.

Code---

Dim dtSQLServers As DataTable

dtSQLServers = SmoApplication.EnumAvailableSqlServers()

Dim strServer As String
For Each dr As DataRow In dtSQLServers.Rows
strServer = CStr(dr("Server"))
'strServer = dr("Server") & "\" & CStr(dr("Instance"))
If Not TypeOf dr("Instance") Is DBNull AndAlso CStr(dr("Instance")).Length > 0 Then
strServer += "\" & CStr(dr("Instance"))
End If

comboServer.Items.Add(strServer)
Next


----------------
is there any other method for this.
Firewall is off on server.

Thanks
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum







































































































































































SQLServerCentral


Search