Fetching connection string from appconfig file in c#

前端 未结 10 975
隐瞒了意图╮
隐瞒了意图╮ 2020-12-19 07:39

I have the following connection string declared in my app.config file:

  
    

        
10条回答
  •  天涯浪人
    2020-12-19 08:12

    Same problem. Based on Merlyn Morgan-Graham and Edward Zhu comments, I rebuilt my project, which used the app.config to create a myapp.exe.config file with the connection string. Original first syntax then worked.

    Other problem: Tried using the project properties dialog to modify the connection string and it added "project.My.Mysettings. to the connection string name. Which caused failure.

提交回复
热议问题