boxhead — 2014-01-10T04:44:57-05:00 — #1
I have a c# web applications that contains two programmes. One of the programmes has a part which accepts a dictionary of contacts (name, email address) which either programme can use.
I now want to split the programmes into separate application on the same web server (different app pools), so I now need app 2 to send a dictionary to app 1. I think the best way to achieve this is via a web service on app 1. I have started the web service (asmx/cs) and think I can get that side of it working, but I can't work out how to get app 2 to reference the web service from app 1.
How do I do this - I can't find anything in the references that looks right! Do I need to compile a dll or anything like that? Any help or pointers in general greatly appreciated
nightstalker — 2014-01-13T04:14:35-05:00 — #2
All you should need to do, is to add a service reference to your other project. Visual Studio should handle the rest. You could also look at creating a WCF service instead of older SOAP service
boxhead — 2014-01-13T11:44:04-05:00 — #3
OK, so I've gone back and changed to a WCF and have added a reference in VS, but if it try this:
NominalCommunicationServiceClient client = new NominalCommunicationServiceClient();
it doesn't work - the service is not recongnised (no intellience or colour coding)! Am I missing something? The page for the service has something about running this:
do i need to do that, or is that covered when i create the reference?
endermb — 2014-01-14T11:29:03-05:00 — #4
Could you not serialise the object to the file system? Get App 1 to write to the file system with your serialised object, and then get App 2 to read from that location.
nightstalker — 2014-01-16T23:50:16-05:00 — #5
That should be done automatically when you add a reference as it generates the classes you need. For the contracts, etc. This is a very strange issue. Can you resolve the WSDL in your browser and is it well formed?