How to use with existing business & data access DLLs & app.config
Options
My data access DLL expects to find a connection string in app.config or web.config. Where would I put that when using LinqPad?
Comments
-
OK, found out I need to create Linqpad.config in the exe dir. Did that and added the connections string and a, appSetting, but can't return them to LP.
Here is my config file:
and here is my code. Both statements return null:
var setting = ConfigurationManager.AppSettings["MySetting"];
Console.WriteLine(setting);
var con = ConfigurationManager.ConnectionStrings["MyConnectionString"];
Console.WriteLine(con); -
For some reason image of config didn't show so here it is. Am I doing something wrong?
OK, I can't paste my config or an imag -
SOLVED - works when running as administrator.