02-27-2015 02:14 AM
i have used a single dialog box connected to a case structure..but the problem is it only executes true case after pressing "OK" button.
i need the false case to keep on executing untill "OK" button is pressed.. please heelp me out..
02-27-2015 02:18 AM
02-27-2015 02:25 AM
are you expecting like this ,
02-27-2015 02:57 AM
In true case i have done addition operation and when i run the vi it will display a message dilog box .
before clicking the message dialog box i need false condition keep on exicuting till i press the dilog box..but its not happening ...
please find the png file attached
thank u
02-27-2015 03:00 AM - edited 02-27-2015 03:00 AM
Hi modi,
THINK DATAFLOW! Use probes to see why it only executes the TRUE case of your case structure…
As you seem to be new to LabVIEW I want to suggest taking all the free online beginner courses offered by NI on their website. They are for FREE!
(And PLEASE stop creating duplicate posts for the very same problem…)
02-27-2015 08:04 AM
Obligitory free training links.
6 Hour LabVIEW Introduction
Self Paced training for students
Self Paced training beginner to advanced, SSP Required
LabVIEW Wiki on Training
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
02-27-2015 08:25 AM
I agree that the spamming of the same question over and over is annoying and makes me LESS likely to help you. However, I will try to answer you.
I believe that you are probably fairly new to LabVIEW. LabVIEW is a dataflow language. As such, each node operates as soon as all of its nodes have data. Your One Button Dialog Box does not produce data until the button is pressed. Therefore, there is no way for the Case structure to execute either the True or the False case until the One Button Dialog Box produces its data.
So, there are several ways to work with this. Several have already been suggest in this or one of the other 3 queries.
You could place the button on the front panel. If it is on the front panel, it will be read immediately and the value of the button will be available. If it is inside of the loop, the value will be available each time the loop is run. So the suggestion to use a button on the front panel would be a good one.
If you need to use the dialog box, you could use a producer-consumer architecture. The dialog would be in the producer and the case code would be in the consumer. I think that this is not as good of a solution, but if this is part of a larger application it may be desirable to you for other reasons. There is an example producer-consumer that you can find in the example finder and I think that there is a template for one as well.
There are other ways to do this as well, but they get more and more complicated and I don't think you have the experience necessary to accomplish them. I also don't think you need to make things that complicated for such a simple task.
Good luck and try not to duplicate questions again.