C#到客户端网络上的SQL Server

时间:2023-01-05 00:45:36

I have a client with an established accounting database for which I want to write a report. I am planning to use VS 2008. I have no difficulty doing this for SQL Server running on my own machine but want to know how best to publish a c# program to run on the client's network SQL Server. So there are two main issues: 1.) How to adapt the connection string for the remote environment? 2.) A recommendation for good remote assistance method for a fledgling contractor working on someone else's network.

我有一个客户端,我有一个已建立的会计数据库,我想写一份报告。我打算使用VS 2008.对于在我自己的机器上运行的SQL Server,我没有任何困难,但是想知道如何最好地发布在客户端的网络SQL Server上运行的c#程序。因此有两个主要问题:1。)如何调整远程环境的连接字符串? 2.)为在其他人的网络上工作的初出茅庐的承包商提供良好的远程协助方法的建议。

2 个解决方案

#1


Store the connection string in a configuration file (Visual Studio will do this for you most of the time now) and just adjust it when you deploy the app on the client's network.

将连接字符串存储在配置文件中(Visual Studio将在大多数时间为您执行此操作),并在客户端网络上部署应用程序时进行调整。

Remote Assistance Method - check out Microsoft SharedView, and if you want to pay for a higher-end solution, LogMeIn Rescue. Edit - Also, check out TeamViewer (www.teamviewer.com).

远程协助方法 - 检查Microsoft SharedView,如果您想支付更高端的解决方案,LogMeIn Rescue。编辑 - 另外,请查看TeamViewer(www.teamviewer.com)。

Additional Information on Remote Clients:

有关远程客户端的其他信息:

SharedView - http://connect.microsoft.com/site/sitehome.aspx?SiteID=94 - Free, requires Windows Live ID, up to 15 people can watch a screen and you can change presenters at any time.

SharedView - http://connect.microsoft.com/site/sitehome.aspx?SiteID=94 - 免费,需要Windows Live ID,最多15人可以观看屏幕,您可以随时更改演示者。

TeamViewer - http://www.teamviewer.com - Free (and / or pay version) - Start up in "Remote Support", "Presenter", "File Transfer", or "VPN" mode. Can switch sides with partner easily. (Warning - I've had issues with using this in Vista with the UAC command prompts).

TeamViewer - http://www.teamviewer.com - 免费(和/或付费版) - 在“远程支持”,“演示者”,“文件传输”或“VPN”模式下启动。可以轻松地与伙伴切换侧面。 (警告 - 我在Vista中使用UAC命令提示时遇到了问题)。

LogMeIn Rescue - http://www.logmein.com - Pay Product (expensive but extremely nice tool for professional client support). One-way (can't change sides with customer).

LogMeIn Rescue - http://www.logmein.com - 支付产品(专业客户支持的昂贵但非常好的工具)。单向(不能与客户改变方向)。

#2


You can use this kind of a connection string to connect clients SqlServer :

您可以使用这种连接字符串来连接客户端SqlServer:

Data Source=190.190.200.100,1433;Network Library=DBMSSOCN;Initial Catalog=myDataBase;User ID=myUsername;Password=myPassword;

For more connection strings click here.

有关更多连接字符串,请单击此

I think you know that but I want to mention you should keep it in your web.config. You may need to deploy your product to clients network. then it will be easy to configure your application.

我想你知道但我想提一下你应该把它保存在你的web.config中。您可能需要将产品部署到客户端网络。那么配置你的应用程序会很容易。

Hope this helps !

希望这可以帮助 !

#1


Store the connection string in a configuration file (Visual Studio will do this for you most of the time now) and just adjust it when you deploy the app on the client's network.

将连接字符串存储在配置文件中(Visual Studio将在大多数时间为您执行此操作),并在客户端网络上部署应用程序时进行调整。

Remote Assistance Method - check out Microsoft SharedView, and if you want to pay for a higher-end solution, LogMeIn Rescue. Edit - Also, check out TeamViewer (www.teamviewer.com).

远程协助方法 - 检查Microsoft SharedView,如果您想支付更高端的解决方案,LogMeIn Rescue。编辑 - 另外,请查看TeamViewer(www.teamviewer.com)。

Additional Information on Remote Clients:

有关远程客户端的其他信息:

SharedView - http://connect.microsoft.com/site/sitehome.aspx?SiteID=94 - Free, requires Windows Live ID, up to 15 people can watch a screen and you can change presenters at any time.

SharedView - http://connect.microsoft.com/site/sitehome.aspx?SiteID=94 - 免费,需要Windows Live ID,最多15人可以观看屏幕,您可以随时更改演示者。

TeamViewer - http://www.teamviewer.com - Free (and / or pay version) - Start up in "Remote Support", "Presenter", "File Transfer", or "VPN" mode. Can switch sides with partner easily. (Warning - I've had issues with using this in Vista with the UAC command prompts).

TeamViewer - http://www.teamviewer.com - 免费(和/或付费版) - 在“远程支持”,“演示者”,“文件传输”或“VPN”模式下启动。可以轻松地与伙伴切换侧面。 (警告 - 我在Vista中使用UAC命令提示时遇到了问题)。

LogMeIn Rescue - http://www.logmein.com - Pay Product (expensive but extremely nice tool for professional client support). One-way (can't change sides with customer).

LogMeIn Rescue - http://www.logmein.com - 支付产品(专业客户支持的昂贵但非常好的工具)。单向(不能与客户改变方向)。

#2


You can use this kind of a connection string to connect clients SqlServer :

您可以使用这种连接字符串来连接客户端SqlServer:

Data Source=190.190.200.100,1433;Network Library=DBMSSOCN;Initial Catalog=myDataBase;User ID=myUsername;Password=myPassword;

For more connection strings click here.

有关更多连接字符串,请单击此

I think you know that but I want to mention you should keep it in your web.config. You may need to deploy your product to clients network. then it will be easy to configure your application.

我想你知道但我想提一下你应该把它保存在你的web.config中。您可能需要将产品部署到客户端网络。那么配置你的应用程序会很容易。

Hope this helps !

希望这可以帮助 !