Hi, All! I’ve encountered the following problem: suppose we have a Codeunit with a call inside it to run some dataport. If error occurs while running dataport (e.g. file to import is not accessible or corrupted), the system shows warning message and waits until user pushes “OK” to skip it. But the execution of the Codeunit is stopped for this moment. Is there any way to ignore such system messages at all and get the Codeunit running on (without user interaction)? Thanks in advance.
No. Unfortunately.
Denis, The only approach you can take in this problem is try to trap the error coditions in your codeunit before you run the datport. eg check the file exists and can be opened with a FILE variable, even open the file and check the csv structure and data integrity. Thinking about it… if you go to this much trouble then why bother with the dataport at all you could do the update to the tables in the codeunit also. Chris
HI You cannot by pass the error messages but if u run the dataport non modally, i guess the rest of the code in the code unit will be processed. have a try on it. WR Hari