I have a LiveCycle designed PDF that I want to make its submit button send the XML data in the form to a .NET webservice. I see how to do that, but I’m not really clear on the webservice side. What should my webservice’s method signature be to accept the XML data?
[WebMethod]
public bool RecieveXML(XmlDocument input)
or
[WebMethod]
public bool RecieveXML(string input)
?
After I receive the XML I just want to email the XML as an attachment (which I can manage on my own), but is there any way for my webservice’s bool return type to cause the PDF to show a success/fail message to the user?
You need to return fdf data (with appropriate mime type set) which has javascript instructions embedded in it. I have not tried it with webservice, I used just a simple aspx page and used
Response.Writeto return the data.Here is format of the data should be returned: Submitting form to asp.net server.
As for receiving the data here is how I did it (the code is in page load event):
As the input is xml string you can use
XmlSerializerto deserialize the input in an instance of a class.