02-05-2014 01:32 AM
I am using a case structure, which has about 8-10 different case and each case has a string constant. I want to show the strings in a single indicator. Suppose if 3 cases runs first then second and then third. Then the indicator should show
" first case
second case
third case"
initially indicator should be empty then as soon as the first case runs indicator should show " first case"
after finishing the first case when second case runs then the indicator should show
"first case
second case"
and so on..Please help me.
Solved! Go to Solution.
02-05-2014 01:37 AM - edited 02-05-2014 01:38 AM
Place your string in a shift register (initialized with an empty string) and append the relevant text (incl linefeed) with each iteration. Place an indicator on the concatenated string.
02-05-2014 02:01 AM
Here it is attached with 3 cases........
02-05-2014 02:22 AM - edited 02-05-2014 02:29 AM
@$agar wrote:
Here it is attached with 3 cases........
Well, that does not look very useful. Try to scale it to 10 booleans! 😮
Here is a quick draft how it could be done. Modify as needed.
02-05-2014 07:22 AM
thanks altenbach
in this solution the indicator is inside the loop.
how can we show the same thing outside the loop, because this vi will be my subvi so i have to pass this to another vi i.e. main vi. and in main vi there will be a string indicator and in that i have to show this.
please reply....
02-05-2014 10:06 AM
tanump1112 wrote:in this solution the indicator is inside the loop.
how can we show the same thing outside the loop, because this vi will be my subvi so i have to pass this to another vi i.e. main vi. and in main vi there will be a string indicator and in that i have to show this.
Please attach a simplified version of your code, showing how you call the subVI and what parts of the code are in the subVI.
Easiest would be to design a small subVI as an action engine that stores the accumulated string in an uninitialized shift register. It would take the new string as input and return the concateneated string as output. You would need a few more modes, e.g. init, read, write, etc.