Hi everyone,
I try to develop a web-service based on XML-Ports that actually allows me to define in NAV what data actually will be published as a web-service - I mean the data will not always be retrieved from the same table but the source could differ based on a setup-table in NAV. Of course I could just manually create the xml-tree in a Codeunit in NAV and publish that codeunit. Yet, I would rather prefer to use XML-Ports to have a strongly typed interface. The question now is (and I have to admit that I have never actually used XML-Ports in NAV and could not find anything about this in the "Developers-bible") if I have a chance to define a XML-Port not to be bound to specific tables but e.g. to use a temporary-record variable instead so that the xml-port could then populate that temporary-table OnPreXMLPort and export that accordingly. Since this temporary table could be populated from various different NAV-tables based on a setup-table in NAV, that flexibility would certainly be of great help.
Thanks a lot in advance!
Jut
0
Comments
Owner of V-Kwadraat (see my blog about Programming and my feed about Gaming!)
The better solution is to define a data structure that covers what you need, and create tables in Navision that replicate this structure, once you have the data structure defined, the rest becomes easy.