Web Service Web.Config File

I have a web service that logs results to a database. Where should I store the connection string so I can change it w/out re-compiling?

Initially I tried storing it in the web.config file under the appSettings element. However, after I connected to the web service from a client, the webservice pulled the web.config file information from the client's machine.

Do I need to create a custom configuration object and serialize it to file on the web service's machine OR is there a way to tell the web service to read its web.config file and not the clients?

Thanks!

0
jwdenny
11/22/2005 4:31:19 PM
asp.net.xml-web-services 7071 articles. 0 followers. Follow

2 Replies
867 Views

Similar Articles

[PageSpeed] 53
Get it on Google Play
Get it on Apple App Store

I figured it out. The web service was one of many projects in the same solution. One of the other projects (a windows application) referenced the web service via the dll instead of as a web reference. When I removed the project reference and setup a dll reference the web service pulled the data from it's own web.config file.

0
jwdenny
11/22/2005 7:11:38 PM
Normally you store it in the web.config file located the webservice directory.

I don't know how the webservice could have pulled the web.config file from a client's machine since the web service runs on the server.
C# / C++ Developer
0
Kelsey
11/22/2005 7:28:51 PM
Reply:

Similar Artilces:

xml web service --uploading the file to the xml web service
how can we upload the file in the xml web service 1.i mean what will be the return value in the proxy class 2.and how am i going to send the file to the xml web service----regards Bipul Kumar Here are some links to articles that helped us get this done: http://msdn.microsoft.com/webservices http://www.microsoft.com/downloads/details.aspx?familyid=06255a94-2635-4d29-a90c-28b282993a41&displaylang=en https://www.sys-con.com/dotnet/article.cfm?id=458 Hope this helps....

Web Site Project: How to configure web service URL in web.config (web service defined in a referenced DLL)
I have a web site that references a business logic DLL project. In the business logic project, there is a web service defined in its app.config file something like this: <applicationSettings>  <MyNamespace.BLL.Properties.Settings>    <setting name="MyNamespace_BLL_MyServer_ServiceName" serializeAs="String">    <value>http://blah.blah.blah.asmx</value>  </setting>  </MyNamespace.BLL.Properties.Settings></applicationSettings> When the web site is published, the web ...

Changing URL in web.config for web service
I added a web reference to asmx file. In web.config - it adds - undefinedadd key="CoreService.CoreServices" value="http://test/CoreServices.asmx I then change it to <add key="CoreService.CoreServices" value="http://test2/CoreServices.asmx"/> But CoreService.CoreServices still looks for http://test/CoreServices.asmx.  What else do i have to change? I think CoreService.CoreServices are hard coded into the source code.  Girijeshhttp://www.girijesh.in/ I think CoreService.CoreServices are hard coded into the source code.  Girijeshhttp://www.girijesh.in/ So no ...

How to call a .net web service from another .net web service?
Hi all,I have developed two asp .net web services using visual studio .net 2003.I wish to call one web service from another web service.I tried adding a web reference of the web service in another web service and was able to do so.but i m not able to access the web methods provided by the web servicecould you please suggest a way to go about itExpecting quick replyThanxCharmy try to make sure that you reference it in the web reference and call it properly this is sample  [WebMethod()] public double CalcDistance(int x1, int y1, int x2, int y2) { Calculator.Service1 calc = new...

Web service in .NET from Java Web Service
Hi there,I'm pretty new to .net (although i have years of experience with the old vb 6, access 2k, as well as java)... and need some with perhaps either some syntax or something.Here is the wsdl.<wsdl:definitions targetNamespace="http://www.dynix.com/schema/book">−<wsdl:types>−<schema targetNamespace="GetBookInfoByISBN">−<complexType name="BookInfoType">−<sequence><element maxOccurs="1" minOccurs="0" name="Title" nillable="true" type="xsd:string"/><element maxOccurs=&quo...

change a web reference to a web service in the config file of an object used by a windows service
In my solution (visual studios 2005), I have a windows service and a business object.  The business object has a web reference to a web service.  I maid the web reference dynamic and it created an applicationSettings section in the appconfig:<configuration>           <applicationSettings>        <Objects.Properties.Settings>            <setting name="Objects_LookupService_auth"        &nbs...

.NET web services Vs Java Web Services
Hello, does anyone know of a book or good source of information that compares .NET and Java Web Services? (I would like soemthing neutral if possible). I am thinking of approaching this subject for my dissertation? Many Thanks Rob Hi Rob, Last year I had to give a powepoint presentation on Web Services. I noticed some good books at barnes and noble that discussed the subject. These books were specific to Java and discussed Web Services in a very clear fashion. They gave some elementary examples that were easy to understand. I have not yet had the pleasure of creatin .NET Web Servi...

Web Services and Web.config
Can the functions within my asmx file access the values in my web.config file. I'm trying to access a value using the following code: ConfigurationSettings.AppSettings("MyValue") The error that i'm receiving is saying that ConfigurationSettings is not declared. how can i reference the web.config values? Do you imported System.Configuration namespace! Inorder to use ConfigurationSettings you have to import that name space! Hope it helps!Sreedharhttp://www.w3coder.orgweblog http://weblogs.asp.net/skoganti Thanks for the reply. I didn't have system.Configuration imp...

web web web
Name: bahadir Email: sensiz_olmuyor_t1_at_hotmail.com Product: Firefox 2 Beta 2 Summary: web web web Comments: web sayfası yapmak Browser Details: Mozilla/5.0 (Windows; U; Windows NT 5.1; tr; rv:1.8.1b2) Gecko/20060821 Firefox/2.0b2 ...

Is web services a part of web Service?
  I have a question: Is web services a part of web server?? And when the client calls web service, it means that client calls web server?? Or is it a different entity in itself which communicates separately both with client and server and acts as middleware application.. I am very confused.. Can someone explain me the architecture...??? Thanks..Dont forget to click "Mark as Answer" on the post that helped you.This credits the member,earns you a point & marks your thread as Resolved so that new users will know where to search for their queries. When you build and dep...

what are web services and what are the advantages of web services?
 Hello  i am new to this .net stuff and i was ask on the job interview what a web services is?and if i did not know given that i had a project ( as a project manager,  or a web developer)   what  is it? how do i start a >NET project on it? what are the main advantages is?  HOW DO I START THIS IN THE INTERVIEW>  and what basic books do i buy?   Hi There, There plenty of source on the net about webservice Definiton: http://en.wikipedia.org/wiki/Web_service http://www.codeproject.com/Purgatory/Defining_Web_Services.asp...

Calling a Web Service from a Web Service
Hello,I was looking for some feedback on calling a web service from within a web service. I've heard that it's not good practice (or not possible). I have a scenario where I think it might make some sense.Within our infrastructure, we've created a web service that handles incoming updates on the statuses of all processes. This has proven to be a good thing since it allows applications to communicate across server to make status updates. It's also used by third party developers and applications to communicate with our infrastructure.Along these lines ... we are planning to create a new compon...

What action by a web service requires an app to update their web reference to a Web Service
I create a web reference to a web service in my aspx web application which returns an XML object. If the owner of the web service makes a change to their object am I required to do an update web reference? What if I dont use the information from the new object? thanks Larry You should make the change only if the contract b/w the two has changed (e.g. parameters, return values), etc.-Mathew Nolton Website=www.cybral.com Email=mnolton@cybral.com Blog=weblogs.asp.net/mnolton If the web service now returns a new element and my class reference doesn't match their new class ref...

changes in web.config file to call web service
Hello,do i have to modify web.config file to add web service??This is my .asmx file<%@ WebService Language="VB" CodeBehind="~/App_Code/service.vb" Class="web.comService" %>Imports System.WebImports System.Web.ServicesImports System.XmlImports System.Web.Services.ProtocolsImports System.Web.Script.ServicesNamespace web    <WebService(Namespace:="http://tempuri.org/")> _    <WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _    <Global.Microsoft.VisualBasic.CompilerServices.Desi...

Web resources about - Web Service Web.Config File - asp.net.xml-web-services

Public Broadcasting Service - Wikipedia, the free encyclopedia
... such as PBS NewsHour , Masterpiece , and Frontline . Since the mid-2000s, Roper polls commissioned by PBS have consistently placed the service ...

The capex data has a services blind spot
The latest investment figures overstate the importance of the mining industry and exclude several services sectors that account for half of all ...

What Martin Parkinson's return means for the public service
... There were 15,000 job cuts announced in the first Abbott-Hockey budget. Even in their second, when these cuts were finished, the public service ...

Survivors of Paris terror attacks attend memorial service
PARIS ended a period of mourning for the victims of last fortnight’s terror attacks with a solemn memorial service attended by 1000 survivors ...

Disney launches DisneyLife, a UK-exclusive online streaming service
Disney has entered the online streaming market with DisneyLife, a brand new service that launched in the United Kingdom on Tuesday (with a global ...

Volvo launches in-car package delivery service in Gothenburg
Filed under: Volvo , Europe , Technology This Christmas, Santa's reindeer will deliver presents to Volvo owners in Gothenburg, Sweden, as part ...

Amazon Reports of Air Freight Service Just the Start, Says Baird
... at $674.43, following an article this morning on Motherboard by Kari Paul stating the company has developed its own trial air cargo service, ...

One-day sale: Get an extra 15% off all VPN services
If you want your private information to stay private and away from the prying eyes of snoops and hackers, getting online with a VPN service is ...

'Uber for helicopters' startup Blade now offers private jet service to Miami, and it wants your flight ...
... to the Hamptons. The startup is now expanding its offerings to include seats on a private Gulfstream IV jet. Dubbed BLADEone, the service ...

Tesla Service Wait Times In Norway Getting Looong
Originally published on EV Obsession. Some of those needing to take their Teslas into service centers in Norway for repairs have been reporting ...

Resources last updated: 11/27/2015 10:51:17 PM