11-15-2012 09:41 AM
Oh, one other thing: the problem doesn't affect global variables either. I had a global array plugged into the script and I didn't need to add 0 to it to get it to work.
DanX
12-20-2012 04:28 AM
FYI:
Just had a similar problem passing a string. Errorcode 1047 when using a control; worked fine using a constant.
Solved by including a "Trim Whitespace.vi" between control & script node input.
Running LV 12.0f3 (32-bit) and MATLAB v2008a. See attachment.
Brgds, Allan
05-14-2013 03:20 AM
I found the same problem only that it exist in the main vi.
I have two shared variables (1D array of double), then uses build array to make a 2D array that is sent as input to a MATLAB node.When I compiled it under LV2011 sp1 it worked fine but in LV2012 sp1 I got error 1047 "inappropriate array size". Replacing the shared variables with a control or constant removes the error.
My workaround is a variation of the "add 0" approach, I have a selector which is always true. On the true input I have my data, on the false input I have my 2D array constant. Works!
I have a really old version of Matlab.