LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to reset array max and min

I'm kind of stuck once again...

I'm having a problem determining how to use a reset button to reset the data inside the array min and max.

I've tried a few different methods and it's not seeming to work correctly.

am I going to have to create two seperate case structures to accomplish this?

IE, if reset button = false then wire the data into an array max and min and display the max value
     if reset button = true then max pounds = 0

I'm stuck in my thinking, I'm hoping someone might have an idea.

posted code below.
0 Kudos
Message 1 of 5
(3,660 Views)

IE, if reset button = false then wire the data into an array max and min and display the max value
     if reset button = true then max pounds = 0

 
For this, do as shown in attached pic.
 
Had a look at your code.
Just wondering,  Why do you have an event structure outside the loop and selected an event in it for your start button??
 

0 Kudos
Message 2 of 5
(3,636 Views)
The start button outside the loop was to simply start the program.  I was looking at an example and it used the start button, as shown to basically start the loop using the button.  That was the main reason..  Basically I was trying to create a "run button" while in the .exe form of the program if that makes sence. 


0 Kudos
Message 3 of 5
(3,613 Views)
Okay so basically the example you showed is only putting in a 0 when the button is pressed.  Since it is showing a max value its not working correctly.  For some reason I believe that I need a memory buffer and when the button is pressed it resets the buffer?  Is this even possible?

Thanky
0 Kudos
Message 4 of 5
(3,601 Views)

Greetings!

   I am not sure if I understand your problem completely. It appears that you are wanting to use event structures (buttons) to run portions of your VI. As devchander mentioned hopefully the picture got you going on the min-max and resetting array. Is that right?

On your next issue, there is an example program which is shipped with LabVIEW that uses event structures that does similar to your application. Please do take a look at that. It is call Acquire-Analyze-Present.VI. You can access this from the example finder. Please let us know if this is not what you are looking for.

Thanks and Best regards
Avi Harjani




0 Kudos
Message 5 of 5
(3,575 Views)