Hi To all,i used progress bar control of 7 array i.e 0 to 7 ProgressBar(PB) with same name pb1 ,but how to write code for each .My code is working if i select 1 PB and there is any other event for pb that i should not click on pb it directly retrieve data from port ,thus we can load pb in a Form load which on loading it directly retrieve data.
To change the value of each progress bar you would type:
pb1(<em>x</em>)<em>.</em>value = <em>value</em>
Replacex with the number of the progress bar and value with the value you want it. So if you wanted to make the 3rd progress bar's value 50 you would type
pb1(3).value = 50
You can change other attributes of the progress bar the same way (like width, height etc.) for the width would do:
pb1(<em>x</em>).width = <em>value</em> To make the value of each progress bar the same you would put it in a loop like this (replacevalue with either a number or another variable):
For x = 0 to 7
pb1(x).value = <em>value</em>
Next x To retrieve a value you would use:
<em>something</em> = pb1(<em>x</em>).value Hope that answers your question about the progress bars :)