AdvancedHMI Software

General Category => Support Questions => Topic started by: cmullis on November 25, 2015, 08:46:35 PM

Title: Reading array of UDT's
Post by: cmullis on November 25, 2015, 08:46:35 PM
I have an array (10000) of UDT's. The udt has 4 DINT's and 1 string in the structure. What is the fastest way to read this type of structure? Using a For Loop will take about 18 minutes based on my calculations. I am trying to pull a bunch of data out of the PLC so that I can parse it and build some reports with it.
Title: Re: Reading array of UDT's
Post by: Archie on November 26, 2015, 07:01:51 AM
Your best chance may be to use BeginReadMultiple to read each UDT element at a time. Even this will take 10,000 reads. Any way you go about it, reading almost 1Mb of data is going to take some time.
Title: Re: Reading array of UDT's
Post by: bachphi on November 26, 2015, 09:18:05 AM
This is a strong case for storing it to a database.