Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7713113
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T01:47:22+00:00 2026-06-01T01:47:22+00:00

I have created a class library as a project. Where I have added a

  • 0

I have created a class library as a project. Where I have added a service reference, which reference is a .svc ( its called OData Service what I am using)

I have created a class that exposes methods and uses this reference to get data.

All is working fine.

Now my doubt is, If I say want to change the url of the service reference, do I have to go open my visual studio solution, then remove old reference then add again with the new reference ?

I now there has to be a better way using config or something, there should be an app.config created whenever I add a reference right ?

This is not happening in my case.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T01:47:24+00:00Added an answer on June 1, 2026 at 1:47 am

    The service reference you created generates code which works against a specific service model. Any service with the same model can be used at runtime with it. The URL of the actual service used at the runtime is passed as an argument to the constructor of the DataServiceContext (the generated code includes a class which derives from this one). There’s no app.config generated for this.

    You can definitely use app.config and load the URL from it in your code and pass it to the DataServiceContext constructor. But you will have to write this code yourself.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a class library that I created using the Class Library project template.
I have created a class library called AddServiceLibrary in which I have a method
I am using the apache library. I have created a class which sends a
I have created a Class Library (Core Processing Component) using C# in Visual Studio
I am using C#. I have created a class which can be included in
I have created a service class for my network connection so that my app
In Visual Studio 2008 I have a Class Library project (called Media ) to
I have a WCF Service application project , a class library project (acts as
I created a very simple WCF class library and added this project to the
I have a class library project which contains a java script file libscript.js which

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.