2. Loops and Execution Structures

  • (1/5) While Loops
    LabVIEW uses graphical loop structures like While Loops and For Loops to repeat section of code.
  • (2/5) For Loops
    Learn how to use NI LabVIEW For Loops to execute a piece of code a predetermined number of times.
  • (3/5) Case Structures
    You can use LabVIEW Case Structures to programmatically execute sections of graphical code based on certain conditions.  This is similar to “if… then… else…” statements in other programming languages.
  • (4/5) Shift Registers
    Explore how shift registers in NI LabVIEW software provide a way to pass data between loop iterations. Discover how you can use them to perform running calculations such as moving averages.
  • (5/5) State Machines
    LabVIEW developers use state machine architectures to build applications quickly.


Execution structures contain sections of graphical code that control how and when the code inside runs. The most common execution structures are While Loops, For Loops, and Case structures. With these structures, you can run sections of code multiple times or execute a different section of code based on a condition. This module explains the functionality of these structures and when they should be used in NI LabVIEW software.

Detailed Explanation

Cumulative Exam: LabVIEW Basics

Test your understanding of LabVIEW concepts by attempting the LabVIEW Basics Test. This test is recommended after completing the modules found in the Learn LabVIEW section. The test includes 20 multiple choice questions.

Begin the exam

Cumulative Exercise: LabVIEW Basics

Assess your understanding of programming within the LabVIEW environment by completing the LabVIEW Basics Exercise. This exercise is recommended after completing the modules found in the Learn LabVIEW section. The exercise involves building a calculator in LabVIEW.

Start the exercise

What Do You Want to Learn Next?