Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Webservice to listen to port 80

Status
Not open for further replies.

dcrooks

Programmer
Aug 8, 1999
12
US
I need to create a webservice to listen to port 80 and read in an XML file. Any ideas?
TIA!


"Use the Right Tool for the Job!"
David L. Crooks
Anteon Corporation
 
There are a number of tutorials in the MSDN docs -- it's easier than you think.

Chip H.


____________________________________________________________________
If you want to get the best response to a question, please read FAQ222-2244 first
 
That narrows it down. Any other examples would help. Thanks!

"Use the Right Tool for the Job!"
David L. Crooks
Anteon Corporation
 
all webservices run by default on port 80. that's one of their great advantages.

second, you can create a method that takes as parameter an XML and mark that method as [WebMethod]. it's as easy as that.

--------------------------
"two wrongs don't make a right, but three lefts do" - the unknown sage
 
Right, I need a web service that is triggered when an XML file is created and then put into a dataset. Do I need a timer?



"Use the Right Tool for the Job!"
David L. Crooks
Anteon Corporation
 
Web services aren't "triggered", they're called. Think of them as really really remote method calls.

So, in your case, it sounds like after the code adds the XML to your dataset, it would make a call to the webservice. The power of Visual Studio makes this easy, as all you'd do (from the calling side) is add a web reference to the web service, by right-clicking on the references branch of your project tree, and selecting "Add web reference".

Chip H.


____________________________________________________________________
If you want to get the best response to a question, please read FAQ222-2244 first
 
No, I need the web service to suck in the XML data.

"Use the Right Tool for the Job!"
David L. Crooks
Anteon Corporation
 
Then write a class that has the WebService attribute attached to it, then write a public method that has the WebMethod attribute attached to it, and accepts a XML string as a parameter.

See:

for a tutorial on how to write a web service.

Chip H.


____________________________________________________________________
If you want to get the best response to a question, please read FAQ222-2244 first
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top