Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Web Service to consume XML document, how?
Message
General information
Forum:
Visual FoxPro
Category:
Web Services
Title:
Web Service to consume XML document, how?
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01017923
Message ID:
01017923
Views:
74
I am planing a Web Service which will receive XML document from our users? I would like to write a MTCOMDLL that will receive the XML document through HTTPS and parse the information into VFP tables. The XML document schema is defined an external XSD file.

How can I use XMLAdapter to achieve this?

Or is there a better way to do this? Maybe in .NET?

I am think of something like this:
DEFINE CLASS MyWebService AS Session OLEPUBLIC
   PROCEDURE NewCustomer(lcCurstomerInfoXML AS String) AS String
      LOCAL loXMLAdapter AS XMLAdapter
      LOCAL lcReturn

      loXMLAdapter = CREATEOBJECT("XMLAdapter")
      
      OPEN DATABASE "mydb.dbc"

      loXMLAdapter.LoadXML(m.lcCurstomerInfoXML)
      
      &&& Save the data into the database

      CLOSE DATABASES ALL

      RETURN m.lcReturn
   ENDPROC
ENDDEFINE
Would this work?

Will appreciate any comments or recommendations!
Dawa Tsering


"Do not let any unwholesome talk come out of your mouths,
but only what is helpful for building others up according to their needs,
that it may benefit those who listen."

- Ephesians 4:29-30 NIV

Dare to Question -- Care to Answer

Time is like water in a sponge, as long as you are willing you can always squeeze some.

--Lu Xun, Father of Modern Chinese Literature

Next
Reply
Map
View

Click here to load this message in the networking platform