Print Page | Close Window

Help needed with web.config

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce 2012
Forum Discription: For .NET 4.5
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=3945
Printed Date: 05-May-2025 at 9:50pm


Topic: Help needed with web.config
Posted By: mseeli
Subject: Help needed with web.config
Date Posted: 25-Jan-2013 at 5:44am
I have a wpf n-tier application made from the standard DevForce template. It is currently using the IIS-Express 7 and is working fine.

the webconfig and the app.config look like this:


Web.Config: (no changes to the one provided by the template except the addition of hte httpRunntime targetFramework

  <system.web>
    <httpRuntime targetFramework="4.5" />
    <compilation>
        <assemblies>
            <add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
      </assemblies>
    </compilation>
  </system.web>

The app.config is also standard an looks like this:

    <objectServer remoteBaseURL="http://localhost" serverPort="50372" serviceName="EntityService.svc" >
      <clientSettings isDistributed="true" />
    </objectServer>

I would like to move it form IIS-Express to the IIS (in a virtual directory)

In Visual Studio I can see the following path:

http://localhost/VisSolutionsWebServer   

I thus changed the app.config as follows:


    <objectServer remoteBaseURL="http://localhost/VisSolutionsWebServer" serviceName="EntityService.svc" >
      <clientSettings isDistributed="true" />
    </objectServer>

When I start the application I get the following error:

on the statement:

await  Authenticator.Instance.LoginAsync();

With the message: "http://localhost/VisSolutionsWebServer/VisSolutionsWebServer/EntityServer.svc could not be activated.

It seems to me that the above address is wrong it should be:
http://localhost/VisSolutionsWebServer/EntityServer.svc

But I have no idea where the wrong address comes from or how I could change it.
What am I doing wrong?







Replies:
Posted By: kimj
Date Posted: 25-Jan-2013 at 8:27am
For somewhat obscure legacy reasons, the application name should be specified in the serviceName and the remoteBaseURL should contain only the ip/machine name.

RemoteBaseURL="http://localhost" serviceName="VisSolutionsWebServer/EntityService.svc"



Print Page | Close Window