13
« on: May 25, 2015, 02:01:16 PM »
Hello I'm reading an array of UDTs that has 7 DINTs (each one holds Year, month, day, hour, minute, second) and then a float for a value. This UDT is 1440 elements long. I need to read in all the values and then put them in a CSV file. I've got it all working except the fact that I can only get it to read as DINTs which makes my float value be split up. This also wouldn't be a huge problem since I can put it back together in VB.net. So that's the first problem. The second one is that I'm doing a read starting at GWTUVDAI_CV.LOG[0]. The read thinks that the number of elements is 1440 (which is actually the array size) but that doesn't include everything that's inside the UDT as well. So the length should be:
1440 * the length of each UDT which if we're using DINTs is 9 (7 for the DINTs and 2 for the float). The problem is the .Read() function won't let me read more than 1440 elements which means it's really only reading up to array element 160 and not reading my entire array. please have a look at my attachment.
thanks