From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

startup event?

Solved!
Go to solution

how?

0 Kudos
Message 1 of 16
(4,493 Views)

When?

0 Kudos
Message 2 of 16
(4,486 Views)

Generate an event outside the event while loop.

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 3 of 16
(4,483 Views)

I mean, I found only this. But I didn't find a startup event? Smiley Sad

Close_event.PNG

0 Kudos
Message 4 of 16
(4,474 Views)

Thanks, now you are starting to provide a few details besides just a one word question.

 

As yamaeda said, you could register for an generate a user event as the very first thing your VI does.

 

Do you actually need a "startup event"?  Why not put the code you want to execute at startup right at the very beginning of your VI and control the order of execution either with wires, or even a sequence structure?

0 Kudos
Message 5 of 16
(4,467 Views)

Actually what  I want to do is quite simple. This program is a report generator. It has simple code to build array of clusters information from a database, but it filters out the values that do not match a specified serial number. So only entries with a specified serial number will go in.

The serial number is entered in the numerical, or even a string control, but once the program is opened I want to wire it with the latest serial number found in the database, so in order that it should act as a default value.

0 Kudos
Message 6 of 16
(4,460 Views)

 


@Ravens Fan wrote:

Thanks, now you are starting to provide a few details besides just a one word question.

 

As yamaeda said, you could register for an generate a user event as the very first thing your VI does.

 

Do you actually need a "startup event"?  Why not put the code you want to execute at startup right at the very beginning of your VI and control the order of execution either with wires, or even a sequence structure?


I will post my current code, so that you can understand :manhappy:

 

0 Kudos
Message 7 of 16
(4,453 Views)

 Your VI makes no sense whatsoever. Are you running this in "continuous run" mode??? 😮

 

Why would you need an event at all?

0 Kudos
Message 8 of 16
(4,448 Views)

 


@altenbach wrote:

 Your VI makes no sense whatsoever. 


I agree.

@altenbach wrote:

Are you running this in "continuous run" mode??? 😮

 


yes :womansad: I could'n think for another way of doing it. what would you suggest insted?

 

Why would you need an event at all?


This is just to replace a "Load DB" button, because it should be pressed only once and in the beginning - it makes no sense either/.

 

0 Kudos
Message 9 of 16
(4,446 Views)
Solution
Accepted by topic author aias

The continuous run button is a debugging tool, not something to use for regular operation, ever!

 

Simply place a while loop around your code and wire the startup code so it is executed before the while loop starts. That's all!

0 Kudos
Message 10 of 16
(4,444 Views)