How to create a web service using an existing XML file in VB.Net

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

I've an XML file that i would like to use in creating a web service. I have
already set up the IIS server and i can run a sample web service.

I tried creating a function so that when the web service is invoked, it will
display the content of my XML file.

Do anyone know what i can do to resolve this issue. Any help will be
greatly appreciated...

Many Thanks..........
 
Hi,

Try something like this

<WebMethod()> _

Public Function ReturnXml() As DataSet

Dim ds As New DataSet

ds.ReadXml("C:\temp.xml")

Return ds

End Function



Ken

-------------------------------

Hello,

I've an XML file that i would like to use in creating a web service. I have
already set up the IIS server and i can run a sample web service.

I tried creating a function so that when the web service is invoked, it will
display the content of my XML file.

Do anyone know what i can do to resolve this issue. Any help will be
greatly appreciated...

Many Thanks..........
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top