Settings.Designer.cs 与 Web.config
我刚刚加入了一个项目,该项目具有一个连接字符串,该连接字符串在 Settings.Designer.cs 文件中定义,也在 web.config 文件中定义。当我需要查看数据库的不同实例时,我必须修改这两个值。我不熟悉为什么使用 Settings.Designer.cs 文件。使用 Settings.Designer.cs 与 web.config 的价值是什么?假设我可以删除连接字符串条目之一...应该将其从 Settings.Designer.cs 还是从 web.config 中删除?
I have just joined a project that has a connection string which is defined in the Settings.Designer.cs file and also defined in the web.config file. When I need to look at a different instance of my DB I have to modify both values. I am unfamilier with why the Settings.Designer.cs file is being used. What is the value of using Settings.Designer.cs vs web.config? Assuming I can remove one of the connection string entries...should it be removed from Settings.Designer.cs or from web.config?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
作为一名 Winforms 人员,现在正在从事一个 Web 项目,我的猜测是,Settings.Designer.cs 正在由在网站上工作的 winforms 人员使用:)
我可能会吹掉 Settings.Designer 中的连接字符串。 CS
Being a Winforms guy myself, and now working on a web project, my guess is that the Settings.Designer.cs was being used by a winforms guy working on a website :)
I would probably blow away the connection string in Settings.Designer.cs