Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Progress Bar.
Message
 
 
To
28/09/2001 17:33:45
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Title:
Miscellaneous
Thread ID:
00562121
Message ID:
00562191
Views:
18
>I`m using MS Progress Bar.
>I have it in a form and I just want give it the porcent acording with my process, I mean, in the form is many events I want give to each event a porcent in the progress bar.
>How can I do it.?
>TIA

Here is the code example, I found in my colleague's application:
    *--- Turn on progress bar.
    oprogbar = create('progressbar')
    oprogbar.progressbar.max = RECCOUNT(tctable)
    oprogbar.caption = "Validation "+tcdbc+"!"+tctable +" with "+ alltrim(str(oprogbar.progressbar.max))+" records.... Please wait"

    *--- Walk the table, firing validations in the table using SCATTER & GATHER.
    lnstart = SECONDS()
    Scan
        ........
        oprogbar.progressbar.value = recno()
    Endscan

    Use IN (tctable)		&& Close passed table.
lnend = SECONDS()
oprogbar.release()
Anyway, I would recommend to use ProgBar from Download section here, it looks nicer and it's based on API functions only, so you don't need to think about Distribution. I made few minor modifications in this class and now I use it widely in my applications. If you're interested, send me a request to my work address nnosonov@thewarengroup.com and on Monday I'll send you all necessary files with a sample code. If it's urgent and can not wait till Monday, send me a letter to nosonov@msn.com, so I'll download this stuff through PCAnywhere and send you.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform