tags:

views:

415

answers:

2

We're getting a "The current configuration system does not support user-scoped settings" compilation exception being thrown when navigating to a WCF service on our staging server.

We're getting this exception through the app consuming the WCF service and when we navigate to the .svc test page directly.

This works fine on our test servers - and the websites are setup in the same way (in IIS, in the filesystem etc. etc.).

Does anybody have an idea of what this would be?

Thanks in advance.

+1  A: 

User scope settings are stored in a config file hidden away in the C:\Users\\AppData\Local\ folder. Maybe the setup of your server prohibits .Net to write files there?

Do you have any user-scope settings? I don't think these are necessary for a service? Maybe you should change the settings to Application Scope and your problem is fixed.

Gerrie Schenck
I don't have a C:\Users folder on either server (staging or test) and the web.config for the WCF service contains no appSettings or any user scope settings - we are only getting this exception for some, not all of the .svc files - is there anything else you can think of? Thanks!
Robert W
c:\documents and settings\... maybe for older Windows versions?There's not much else I can think of right now...
Gerrie Schenck
A: 

This was bugging out because one of the settings in a project that the WCF webservice was referencing had its scope set to "user" rather than "application".

So I would recommend people being careful that they check the projects being referenced by the webservice project, as well as the webservice project itself, and make sure the scope of all the settings is application rather than user.

Hope it helps somebody who's trying to rack their brain about anything similar.

Robert W