开发者

Multi Tier Platform will not retrieve database connection string

Using Visual Studio 2010 and C#: I am developing a multi tier application. Client will talk to WCF service platform -> WCF talks to Business Layer -> Business Layer talks to Database access layer. I'm developing these from bottom开发者_JS百科 up. From a Windows application I call the Business Layer, which calls the Database Access Layer works just fine.

When I add the WCF Service layer - my WCF test will call the service, which calls the business layer, which calls the database access layer. That is where the problem happens. The first step is to get the Connection String. When called from WCF I get: Trusted_Connection=yes; Data Source=; Initial Catalog=; When called from any other base (like the Winform project - without WCF) it gets the values from the config file and works.

I'm sure it is a simple configuration I am missing, but I have not been able to find it yet. I would appreciate any guidance you may be able to offer.

Bill


Sounds like you don't have your connection string values in the Web.config file for your WCF service. Since the business and data layers are being called from the WCF service, the config values will need to originate in the WCF Web.config.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜