02-28-2007 03:39 PM
03-05-2007 10:26 AM
hi Jarrod S.
Sorry about the delay getting back to you with the example. I have been pulled out from this task for a while due to other priorities. Here is the example (attached). I think having many loops have caused inconsistent result, so I'm trying to set flags to control the condition. But so far still have no success.
dphan128
03-05-2007 11:02 AM
03-05-2007 11:11 AM - edited 03-05-2007 11:11 AM
Message Edited by Jarrod S. on 03-05-2007 11:11 AM
Message Edited by Jarrod S. on 03-05-2007 11:13 AM
03-05-2007 01:41 PM
Jarrod S.
Thank you for the review/feedback of my code. I knew there were lot of room for improvement there. I enjoyed reading them since they have given me ways of improving my LabVIEW programming skill significantly! And I'm sure to remember those advises for years to come!
Back to my problem, I was thinking about how to "flush my queue" when taking a look at the Consumer Design Pattern template that you have mentioned. But didn't quite figure out exactly how the code would be. I'm staying with my current seperate loop because I don't have much times to re-design the whole scheme as you have suggested. But I'll be sure to use that principle on my next program.
dphan128
03-05-2007 02:02 PM
@dphan128 wrote:
Jarrod S.
Thank you for the review/feedback of my code. I knew there were lot of room for improvement there. I enjoyed reading them since they have given me ways of improving my LabVIEW programming skill significantly! And I'm sure to remember those advises for years to come!
Back to my problem, I was thinking about how to "flush my queue" when taking a look at the Consumer Design Pattern template that you have mentioned. But didn't quite figure out exactly how the code would be. I'm staying with my current seperate loop because I don't have much times to re-design the whole scheme as you have suggested. But I'll be sure to use that principle on my next program.
dphan128
03-06-2007 11:46 AM
Jarrod,
Here are my thoughts:
-The "value change" event queued up if I keep pressing the start button more than once. So I was thinking on how to accept only the first value change and discard the rest.
-Or can I change it to a "mouse down" event and use the discard function.
-Or how I can use the template to do the same thing
dphan128
03-07-2007 11:26 AM
I was able to fix my problem by setting "condition flags" to control the value change event. But now need to figure out how to prevent the same thing (operator clicking more than one time) when dealing the mouse's right click. (see attached).
dphan128
03-07-2007 01:13 PM
03-07-2007 01:34 PM
Altenbach,
Thank you for the modified sample code. But now the right click action doesn't do anything! I mean it doesn't start the action as it supposes to.
dphan128