LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VI Analyser - Arrays and Strings in Loops

Solved!
Go to solution

Hi everybody,

does anyone know the problem with this special failure of the VI-Analyser?

- I must not use "Concatenate Strings" or "Build Array" functions in loops -

 

I try so hard to fix all failures shown in the result but i can't get rid of thisone!

Is there a simple array manipulation function, wich manipulates every element in the same way?

Otherwise i don't know how to fix this issue.

 

Thx 4 ur help

 

 

0 Kudos
Message 1 of 4
(2,264 Views)
Solution
Accepted by topic author LabMartin

You can use a 'Format into string' with '%.2f°C' instead of those 2 functions. If it's more efficient i don't know, but it should get rid of the warning.

Not all warnings can be fixed ...

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
Message 2 of 4
(2,244 Views)

Thank you very much!

0 Kudos
Message 3 of 4
(2,233 Views)

@Yamaeda wrote:

You can use a 'Format into string' with '%.2f°C' instead of those 2 functions. If it's more efficient i don't know, but it should get rid of the warning.

Not all warnings can be fixed ...

/Y


Ditto that!

 

The motivation for that warning is driven by concerns over memory allocation. Firstly to guard against the possibility of an ever growing need for memory and secondly the slow down that happens as the array holding the data (output tunnel or shift registers for example) grows and the OS has to allocate more memory.

 

 

The memory required by that code construct is bounded by the maximum sized of the input ray of floats. The slow down issues will be limited to either the first time that code executes OR if the input array suddenly increases.

 

Since only YOU can tell if the array of floats will be growing as the application runs, the VIA is helping you out by alerting you that you should think about the code and decided if there is an issue.

 

For situations like that I will put comments in the code explaining why the warning is OK OR will modify the VIA settings to skip that check for that VI.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 4 of 4
(2,220 Views)