How can I programmatically read read Table and field properties such as field names, types and lengths using Web Services?
Thanks in advance,
Ricardo Talbot
IRISCO
*This post is locked for comments
How can I programmatically read read Table and field properties such as field names, types and lengths using Web Services?
Thanks in advance,
Ricardo Talbot
IRISCO
*This post is locked for comments
Happy to help, shout if you start down this path and run into any problems and i can assist,
You will need two different codeunit functions, the first will be a "Retrieve tables" function with a parameter of a XML port pointing at the "Table Information" table or possibly the "Object" table and any fields to pass filters in separate fields, you pass in the filters and the XML port returns the tables details
The second function will also have a XML port pointing at the Field table and returning fields based on the table filter passed
Any additional information you need like keys, option string & so on you can retrieve using the field ref & table ref
Thanks Neville,
I'm definitely going to explore that approach.
Ricardo.
Hi
Yes you can, there will be a few steps though,
I am guessing you would be wanting to pass a table name to nav and get a list of fields and properties back?
If so the best way would be to create a codeunit and XML port combination, the codeunit will take a parameter of table name and pass back a set of fields & Table is required with their properties
You can get to these fields and properties by using a RecordRef & FieldRef variable in the codeunit combined with the Field dynamic table to get a list of all the fields in a table to loop through
Hope this makes sense,
Cheers
Neville
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,280 Super User 2024 Season 2
Martin Dráb 230,235 Most Valuable Professional
nmaenpaa 101,156