Feed into a table from more than one file

Hello everybody We have developed an external system to recieve calls (either via modem or via internet) from our service items, placed around in the country. The program-packets we recieve contain information from which the service orders are generated, and further it creates a comma separated file containing a record to the “Service Header” and the “Service invoice line” in Attain 3.10 I have made a dataport which feed in the records to attain, it works OK.[:D] Until now all the records have been in one file. For some reason I really don’t know, the developer of the external system wants to create one file per service order. My question is: Can I modify the dataport to be run with serveral files and after running, move or delete the files? If possible, How do I recognize the different filenames[?] Best regards Karl

Your best bet would probably be a codeunit 1) Read all files in a directory (Use the File Table) 2) If a file is found, call the Dataport with that filename 3) Move/Delete/Rename the processed file. You will have trouble moving/deleting/renaming a file from within the Dataport as the file will be open as long as the dataport is processing. Hope this helps.

Or you skip the dataport and use a codeunit for the import…