Add connectionstring in app.config

后端 未结 6 1852
Happy的楠姐
Happy的楠姐 2020-12-17 07:05

I have a class library in C# has has several classes and a app.config. I have put ConnectionString in app.config as follows:


    &l         


        
6条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-17 07:46

    If you are running Web project with Class library, add connection string to web.config inside the Web project

    If you are running Console/WinForm project with Class library, add connection string to app.config inside the Console/WinForm project

    modifying config in Library project will not work in your case.

提交回复
热议问题