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.
You've got a couple of options. There's Get Date/Time In Seconds and Elapsed Time functions on the Time and Dialog palette. To use the first, get the start time outside the while loop and inside, use it again and subtract from it the start time. This gives you elasped time. If greater or equal to the target, stop the loop. With elasped time, you just have to set a target time and when it has elasped, the Boolean output called Time Has Elapsed goes true. In both cases you should probably or the time has elapsed value with a front panel Boolean so that you can stop the loop at an earlier time if desired.