c# - How to publish a ASP.NET MVC project with separated DbContext -


i have these 5 projects: dataclass, datalayer, servicelayer, viewmodel, viewlayer. viewlayer project asp.net mvc project , it's project going published.

my problem visual studio used detect dbcontext in datalayer , ask me connectionstring doesn't recognize anymore , i'm having problem (i've tried put connectionstring in web.config file in server didn't work.)

so problem published project doesn't work since doesn't have connectionstring. how can publish project specifying it's connectionstring?

p.s.

i've tried putting connectionstring in viewlayer->properties->package/publish sql doesn't work either.

p.s. 2

i've tried vs2013 community , vs2015 ultimate preview (the earliest version)

you have set proper config transformation , update

see below links https://msdn.microsoft.com/en-us/library/vstudio/dd465318(v=vs.100).aspx

the following link has options setting connection string outside web config

http://sedodream.com/permalink,guid,604eadfe-46bf-4989-bac8-814e2701e52a.aspx


Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -