we are planning to integrate webemthods with Ariba by sending cXML via HTTP post to Ariba. Ariba provides a DTD file through which we can create required documenttypes. The problem is I want to create a flowservice for sending purcase order. So I have create a documenttype using DTD that ariba provides and used documenttoXMLstring to convert the document to xmlstring and then used pub.client.http to post it to Ariba.
The problem here is, the DTD Ariba is a generic one and has data type definitions for other documents as well other than purchase order ( for example PurchoutOrder mesage etc.,). So when I send the message, some unnecessary tags as well are getting added to cXML and this is causing issue in Ariba side. When I do documenttoXMLstring, can I avoid certain segments of the document ? or what is the best approach here?