Implode / Explode
LabVIEW lacks native implode/explode functions for strings, to split a string into an array and vice versa. This is easily feasible thanks to the Spreadsheet String To Array function and its opposite Array to Spreadsheet String, but it's useful having a couple of VIs ready to do the work.
Download explode.vi (VI for LabVIEW 2016)
The explode function is pretty straightforward, but imploding is a little harder since the parallel function puts a carriage return / line feed at the end of the resulting string, and we need to remove it applying a trim. Trim is not the best function in performance and could add more problems (for example if the last chunk has a white space at the end), so I have implemented an alternative simple for-loop mechanism.
Download implode.vi (VI for LabVIEW 2016)
Check the code and select the mode you are mor confortable with.
Comentarios
Publicar un comentario