NewPeriodicTask2
Lee D Papworth
3-10-19
I have been using NewPeriodicTask2 to import xml files for a number of different customers without any issues.

I have a customer who uses the background task feature to import tab delimited order files. I am wanting to convert them from this and use NewPeriodicTask2 so the imports are not running on the main thread.

However when I attempt to open the file to read and process it I get this error:

2019-03-08 17:53:36 /THREAD(2) Auto Import Orders - Begin
2019-03-08 17:53:36 /THREAD(2) Processing goporder036726050.txt
2019-03-08 17:53:36 /THREAD(2) ERROR: Opening an import file from non-main thread: D:\GalaxyImport\goporder036726050.txt
2019-03-08 17:53:36 /THREAD(2) dump of call stack
2019-03-08 17:53:36 /THREAD(2) 0D27C871 + 1581 halcust\Tools\GOProcess.hal: (no function )
2019-03-08 17:53:36 /THREAD(2) dumping stack due to ERROR: Opening an import file from non-main thread: D:\GalaxyImport\goporder036726050.txt
2019-03-08 17:53:36 /THREAD(2) --------------------------------------------------
2019-03-08 17:53:36 /THREAD(2) 0 0x00754BF3 - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 1 0x00534D88 - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 2 0x006061FD - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 3 0x007053BA - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 4 0x006F02E2 - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 5 0x006F16E9 - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 6 0x006EDF55 - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 7 0x0068C3C8 - 0x0000000000000000
2019-03-08 17:53:36 /THREAD(2) 8 0x77648484 BaseThreadInitThunk - 0x0000000077648460
2019-03-08 17:53:36 /THREAD(2) 9 0x77A541C8 RtlAreBitsSet - 0x0000000077A54140
2019-03-08 17:53:36 /THREAD(2) 10 0x77A54198 RtlAreBitsSet - 0x0000000077A54140
2019-03-08 17:53:36 /THREAD(2) --------------------------------------------------
2019-03-08 17:53:36 /THREAD(2) 8549001531
2019-03-08 17:53:36 /THREAD(2) ERROR: Closing an import file from non-main thread

With xml files I do not open them but use the ParseXMLFile command.

I have rechecked my code and everything is all correct. It just seems I cannot open them as I normally would when I use the NewPeriodicTask2 command.

Customer is currently running 8.2 2016-12-18 (build 82211904) I am in the middle of migrating them to 8.5 and would like to get this resolved as part of the migration.

Any ideas?

Thanks


Lee Papworth
Leave Comment
You can subscribe to notifications for this post by selecting the 'star' icon on the top right corner of the post.
Latest Posts
David Delač
Hi Piotr, The log entry:
2024-12-14 08:40:43 0.000 CallHal(IsHansaWorldCustomer) appears because the server is running with the verbosity=debug-detailed setting in its parameters.txt file. Thi...
09:43 16 Dec 2024
Brittany McGrath
Hi Vaughn, I can confirm this has been fixed now and is live in Standard ERP 2024-11-20 Version: 85556786. Thank you. ...
10:04 10 Dec 2024