LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how can I make vi run faster?

Solved!
Go to solution
Solution
Accepted by Emna20

Here's what I would probably do. No need for the search button, just populate the fields whenever the ID changes. (The indexing is outside the event structure so it also updates once when the loop is entered.)

 

DBbyID.png

 

 

Message 21 of 37
(1,523 Views)

hi ,

thank you everyone .

if i change the ( ID , Name , Brand , Reference ) in the database when the program is running . this change is not appear in LabVIEW . could you please help me .

0 Kudos
Message 22 of 37
(1,489 Views)

@Emna20 wrote:

hi ,

thank you everyone .

if i change the ( ID , Name , Brand , Reference ) in the database when the program is running . this change is not appear in LabVIEW . could you please help me .


Post your code. It's not clear what advice you took or didn't take... There are a few posted solutions, and some made (reasonable) assumptions. If you use one, we need to know which one.

0 Kudos
Message 23 of 37
(1,486 Views)

hi ,

i use the solution posted by  Knight of NI 

0 Kudos
Message 24 of 37
(1,482 Views)

Altenbach's solution won't continuously update the strings. Only once when started. This made most sense  to us, but apparently isn't what you want.

 

Move the code that updates the string to the time out case of the event structure (that you need to add). Also wire a reasonable time to the TO terminal... 

0 Kudos
Message 25 of 37
(1,458 Views)

@Emna20 wrote:

hi ,

thank you everyone .

if i change the ( ID , Name , Brand , Reference ) in the database when the program is running . this change is not appear in LabVIEW . could you please help me .


If the database actually changes (I mentioned that long ago) your code would be highly flawed because the values in the ring and the values later read from the database would be completely unrelated. You could use my code and add a "refresh" button to re-read the database and place the 2D string array into a shift register and reset the ring items to the new database entries. You cannot necessarily rely that the current ring value corresponds to any particular database entry. What if it valid item 10 is selected and somebody would remove all but 5 items from the database??

LabVIEW is a programming language, so everything you need can be done, you just need to decide what you need.

Message 26 of 37
(1,446 Views)

hi

Could you please explain what you mean in a VI 

0 Kudos
Message 27 of 37
(1,405 Views)

@Emna20 wrote:

hi

Could you please explain what you mean in a VI 


This is a long thread and I "meant" a lot of things. Are you referring to any particular statement?

 

In any case, I am currently posting by phone and don't have access to a computer.

0 Kudos
Message 28 of 37
(1,370 Views)

hi,

i want to know if there is  any other solution for this topic : https://forums.ni.com/t5/LabVIEW/how-can-I-make-vi-run-faster/m-p/3931129#M11171833

 

0 Kudos
Message 29 of 37
(1,345 Views)

What have you tried? Can you post some code?

0 Kudos
Message 30 of 37
(1,296 Views)