06-15-2010 06:19 PM - edited 06-15-2010 06:21 PM
Hi, I am trying to clear up the string by clicking a button.
I attached a picture of the block diagram within this posting.
as you guys can see, I want to clear "read string" and "string to write", which are in the case structure.
However, though I click the button, the string doesn't go off.
Please help me out of this problem.
06-15-2010 07:20 PM - edited 06-15-2010 07:23 PM
Hmm... it works for me. You do know that as soon as you clear the Read string, the serial read will populate it again. So it will appear to not clear. However, the write string should clear just fine.
Also, if the code is in the delay sequence, the strings will not clear until the delay is over because the code will not read your buttons until the delay is done.
06-15-2010 08:42 PM
06-15-2010 08:46 PM
06-15-2010 08:46 PM
Attach your entire vi and any subvi's that it calls. I see nothing wrong with your picture.
06-15-2010 09:20 PM
06-15-2010 10:17 PM - edited 06-15-2010 10:18 PM
It works just fine for me.
If you are still having problems, try running your VI with highlight execution turned on to see how it is executing. Maybe put a Beep VI inside that case structure so you can hear that the case is executing.
06-16-2010 01:22 AM
06-16-2010 09:24 AM
JTAG wrote:
mamake sure that you don't have some defualt value for this string.
How would that cause a string not to clear?
06-16-2010 09:49 AM
Perhaps that's the problem: Your buttons have switching behaviour and your cases are wired to be executed on button press (true) so clearing the strings only works when pressing a button, not when releasing it! I'd suggest to use latching buttons and an event structure.