Threaded Progress Bar

I’m having problem with my progress bar:


on clicked theObject

set uses threaded animation of progress indicator "progbar" of tab view item "test" of tab view "tab" of window "main" to true
		start progress indicator "progbar" of tab view item "test" of tab view "tab" of window "main"

<do stuff>

		stop progress indicator "progbar" of tab view item "test" of tab view "tab" of window "main"
end clicked

now this works fine on first run. the bar appears, runs, then disappears.

However if I run it again (click button again) the Bar will stop at the end but still be visible. any thoughts? ^?:frowning:

managed to solve by adding:

set visible of progress indicator “progbar” of tab view item “nvidia” of tab view “tab” of window “main” to false

at the end and same but True at the top.