安装后的问题 [英] After Installation problem

查看:44
本文介绍了安装后的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

先生,下午好,
我是Dinesh ..
我正在使用SQL Server 2005作为后端在ADO.NET中创建一个项目. 我有一个问题,就是在将我的项目部署到其他计算机上进行安装后..如果目标计算机服务器名称与我在应用程序中使用的服务器名称不匹配,我的程序会给我错误消息吗?
我使用此代码:

Data Source=Dinesh; Initial Catalog=college_Management_System; User ID=sa; Password=*****;


请尽快给我回复先生...困惑| :confused:

Dinesh92

Good afternoon sir,
I m Dinesh..
i m creating a project in ADO.NET with SQL server 2005 as a back end..
i have a question that after deploying my project for installation on OTHER machine..will my program give me error if destination machine server name does not match with my server name which i have used in my application..??

i used this code:

Data Source=Dinesh; Initial Catalog=college_Management_System; User ID=sa; Password=*****;


plz reply me sir soon...Confused | :confused:

Dinesh92

推荐答案

是.
您必须引用正确的SQL Server实例,否则它将失败.
通常,您只需要将此文件保存到配置文件中,这样就不必每次安装都更改代码.
Yes.
You have to refer to the correct SQL Server instance, or it will fail.
Normally, you would but this into a configuration file, so that you do not have to change your code for each installation.


如果名称不匹配,您肯定会收到错误消息.至少您会看到无法连接到xyz"或s.th.类似.
使用配置文件存储所有数据库凭据.

我建议您从这里开始阅读:管理应用程序设置 [
You will surely get an error if the name doesn''t match. At least you''ll see "Cannot connect to xyz" or s.th. similar.
Use a config file to store all DB credentials.

I''d suggest you start reading here:Managing Application Settings[^]

regards
Michel


这篇关于安装后的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆