Home > English > The specified named connection is either not found in the configuration, not intended to be used with the EntityClient provider, or not valid.

The specified named connection is either not found in the configuration, not intended to be used with the EntityClient provider, or not valid.

The specified named connection is either not found in the configuration, not intended to be used with the EntityClient provider, or not valid.

I wanted to share some bad with the good. I typically have a WCF RIA Services Class Library for every logical line of business in my enterprise application. With that said, I tend to have several libraries that are dedicated to different modules in my application.

When you create a new WCF RIA Services class library, it creates two projects. You get a project for the client and one for hosting the data access. One of the common mistakes I can make is to forget to copy the connection string information from the web project to the underlying hosting web application.

The title of this blog is the message from the exception that gets thrown if you forget to add the connection string entry in the underlying hosting web application web.config file.

This may not solve all of your problems with this exception but it is one to thing to remember.

Advertisements
  1. June 19, 2011 at 7:43 am

    Just wanted to let you know that this blog post has helped at least one person solve this problem quickly. Me.

    Thanks

  2. Michael Bihler
    July 1, 2011 at 8:06 am

    And at least a second person too! Thanks for your post!

  3. July 16, 2011 at 1:22 pm

    Thanks a lot dude!!! The message coming from sliverlight was too scary!!! Third 🙂

  4. August 28, 2011 at 9:55 pm

    I liked your article is an interesting technology
    thanks to google I found you

  5. September 14, 2011 at 8:40 pm

    I value this excerpt, thanks.

  6. September 15, 2011 at 2:33 am

    Especially liked the excerpt, many thanks.

  7. September 22, 2011 at 9:44 pm

    Thank you. That was my problem.

  8. Andrew
    September 25, 2011 at 10:00 pm

    Thank you!!!

  9. Venkat
    December 5, 2011 at 3:54 pm

    Thanks God! You saved me. After one day i found this 😦 You saved my time. Thanks a lot for you and your post.

  10. rozey
    January 31, 2012 at 2:05 am

    Hi there,
    i created WCF project; by default it created silverlight project and web project. In web project i have created edmx file and domain services, its working fine on my local system. Upon uploading to shared hosting; it generate that error.
    would you please explain what is mean by underlying hosting web application in my project.

  11. David
    April 10, 2012 at 5:33 pm

    Thanks!

  12. November 15, 2012 at 3:03 pm

    In web project i have created edmx file and domain services, its working fine on my local system. Upon uploading to shared hosting; it generate that error. Please could you give me any idea on what to do?

    • November 22, 2012 at 5:18 pm

      Hi Moses,

      I would check that your web.config includes the necessary mime-types as it could be something as simple as this.

      If that doesn’t work ping me back and we can try something else.

      Matt

      • November 26, 2012 at 4:14 pm

        I ran a check on my web.config and it includes all the necessary mime-types and yet it does not work. Please I would be glad if you can help me out here as this is causing me some embarrassment. the site name http://www.mobileshawarma.com you can check it out.

        I appreciate your help if possible.

      • November 28, 2012 at 9:22 am

        Hi Matt,

        Just to update you with my script. In my web.config file u have the following script

        Please am I missing something or what?

        I really need your help or help of anyone who can help me out here.

        Thanks.

        Moses.

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: