We have a Visual Studio 2010 solution with multiple projects. The startup project is a winforms project and has a reference to a class library project in the same solution. The class library project has a web reference to a classic ASP.Net web service not in the solution. So the dependency chart is like:
Winform startup project -> Class Library Project -> ASP.Net web service
Due to some constraints, we have to keep the web reference on the class library project.
The code works perfectly fine. The startup project calls a class's method in the class library and the class method calls the web service.
The question is - how do I make the URL of the web service configurable? The app.config file on the class library has the URL to the web service. But the solution does not use that app.config at runtime.
I changed the reference.cs (under web reference on the class library) file's constructor to read the value from config file.
this.url = read from config file.
But I think Reference.cs will be overwritten the next time the web reference is updated.
I am sure there is a better solution to this problem? Please help.
All code is written in C# and we are using .Net 4.0.
Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.
This warning has to be one of the most commonly issued warnings in the history of PHP. The article explains why this warning arises and what to do to mitigate the problem.
How this Happens
HTTP headers include many different kinds…
HyperText Transfer Protocol (http://www.ietf.org/rfc/rfc2616.txt) or "HTTP" is the underpinning of internet communication. As a teacher of web development I have heard many questions, mostly from my younger students who have come to t…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel.
Part 1 of this series discussed basic error handling code using VBA.