You would basically have to:
Create the progress bar before the FOR loop
Update the progress bar inside the FOR loop, with an expression that indicates percentage done (for example, recno() / reccount())
Destroy the progress bar after the FOR loop
You should make a generic progress bar, or use a ready-made solution. I believe you can find some in the Universal Thread download section. Perhaps there is one in Visual FoxPro sampels, as well.
If you make your own, creating it as a class makes it easier to use.
>I want to use Progress Bar when i create the Record. the code below shows how to create record, on click event of the cmdcreate button.
>
> local lnfrom, local lnto, local lncounter
>
> lnfrom = thisform.txtfrom.value
> lnto = thisform.txtto.value
>
> for lncounter = lnfrom to lnto
> append balank
> replace regno with lncounter
> next
>
>my question is how to use progress bar when i creating the record?
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)