06-02-2010 09:19 AM
Hello,
I have a string indicator where every time through a while loop I concatenate more data by making use of shift registers as shown in the simplified attachment.
The new data is added to the top of the indicator and old data is pushed down
Is there a way to have the new strings added to the bottom of the indicator and the older strings pushed up? This would be more like a standard terminal window.
I'm using labview 8.2.
Thanks.
Solved! Go to Solution.
06-02-2010 09:29 AM
06-02-2010 09:30 AM
i think in your case, you can't really distinguish between a text added at the bottom or at the top of your string because you use always the word "text" to add...as you programmed it, the text is added at the bottom of the string (that means the text in the loop is added to the bottom). Try to right-click your string indicator, choose "create property node" and the use a property node "text--Scroll position" to specify the position of your scroll bar...
hope this helps,
christian
06-02-2010 09:33 AM
06-02-2010 09:57 AM
Hmm. I don't think I explained this very well.
I understand the additional string is being concatenated and added to the end of the bigger string. What I'm trying to solve is how the data is displayed in the string indicator.
In the attached screen capture Current_1.jpg so you can see how the string starts at the top of the indicator. When additional strings are added, they are added at the top and the older text is pushed down.
The behavior I'd like is to have the newly concatenated string added to the bottom of the indicator and have the older text push upward. I manipulated the jpg to show the desired result in the attached Desired_1.jpg.
Again this behavior is common in a windows command prompt window or in a unix shell. The current, most recent line is at the bottom of the window and older entries move upward.
Thanks.
06-02-2010 10:06 AM
It looks like you need a bottom justification which just isn't an option I can find.
What you could to is put some blank lines in your data, enough to fill the text indicator. Then as you add new data, it will appear at the bottom. With careful coding, you could keep track of how many blank lines you have and delete one from the top as you add new data to the bottom until you've removed all the blank lines and now have an indicator full of real data.
06-02-2010 10:16 AM
06-02-2010 10:36 AM
Hey,
I just tried it and seems like what you want ... i did in for loop for testing ..
Hope it helps
HS
06-02-2010 01:14 PM
Thanks HS. Nice solution to the problem.
That's the behavior I'm looking for. Kind of a strange way to get there.
06-02-2010 01:41 PM - edited 06-02-2010 01:41 PM
You can also do this using queues.