1

I'm using Microsoft Connection Dialog in my project to retrieve a SQL Server connection string from a dialog box that shown to user.

I want limit users to only select databases from a local machine or SQL Server installed on current computer.

How to know that retrieved connection string is a remote connection and how to deny that?

Computers are located on a LAN network..

Sample connection string generated by dialog:

Data Source=SAEED-PC;Initial Catalog=myDB.MDF;Persist Security Info=True;User ID=xx;Password=xxxxx
4

0 回答 0