04-29-2019 02:20 AM
Hello everybody
I have to make one progressbar for my program, but I do not know, how can I create a progressbar.Can anyone help me?
thank you
04-30-2019 06:41 AM
Hi FazelSCH,
it depends on where you want the progressbar to appear and how it should look. Sadly there is no buildin progressbar as a UI Element for Dialogs, but you may display one in the Statusbar:
http://zone.ni.com/reference/en-XX/help/370858N-01/comoff/autoloopinit/
Is this what you're looking for?
Cheers,
Jan Göbel
Staff Technical Support Engineer
National Instruments
05-07-2019 02:17 AM
Hi Goebel
Sadly no,I leave my program attached, you can look and understand my opinion better
05-09-2019 03:05 AM
Hi FazelSCH,
I had a look at your code, my first guess would have been, that the new file format is simply faster and that way you don't see the progressbar running through all steps, but since you use the Pause() function you should definetly see it.
I cannot explain this behaviour directly. Can you try reducing your code to the point, where the progress bar starts working again? If you simply delete the whole For-Loop, does it work?
The only thing I recognized is, that you're not using the "next"-Statement for your for-loop. This seems very unusual to me and I wonder that it even works. Maybe this is causing the behaviour, since you are stuck in the for-loop or something like this.
If you want a loop to run a maximum number of times, but may break in between, use a while-loop and a counter-variable to determine the maximum number of iterations.
I hope this helps. If you can break down the code to a specific function (e.g. ChnResampleFreqBased) that causes the progressbar to not work anymore, I can debug that further!
Cheers,
Jan Göbel
Staff TSE
National Instruments