Add "Progress Meter" to a working VBA routine (1 Viewer)

EEH_Help

Member
Local time
Today, 08:52
Joined
Feb 15, 2020
Messages
32
Good afternoon:

In a different post (https://www.access-programmers.co.u...-allow-listboxs-multi-select-extended.318906/), I received some fantastic help from expert **MajP**.

In his final solution, MajP included a progress meter. I find this progress meter so great that I now would like to include in other databases which require some processing time.

Please find attached 3 DBs... I'll recap the procedures below:

*** "01 Compare Tables" *******

- This is the final version (with limited data) provided by MajP.
- Upon opening the file, form "F01_MainMenu" automatically opens.
- Select "AICRAFT" from listbox.
- The click "View Change Log".
- At this point, the **Progress Meter** kicks in and provides visual status feedback to the user.

Added objects:
- Form "frmMeter"
- Modules "clsDualMeter" and "clsMeter"

The above objects were somehow tied into the module(s) "modCompareTables" and/or "modGlobalCode". No reference to the objects were made in forms' VBA.

Again, this progress meter works great... ** no changes are required for this version! **


*** "02A Generate Products v01" *******
- This DB includes a completely different routine... it is totally independent from file "01 Compare Tables".
- Upon opening the file, form "F01_MainMenu" automatically opens.
- Click on command button "Generate Master PK Table".
- Within approximately 5 seconds, message box pops up indicating that 100 records were added.
- This version also works great and does NOT require any modification whatsover.


*** "02B Generate Products v02" *******
- This DB is an exact copy of "02A Generate Products v01".
- In this version though, I have included the progress meter objects: "frmMeter", "clsDualMeter", "clsMeter".
- Since this DB is a replica of v01, it naturally wors in the same fashion.

Here's what I need some help with (in version "02B Generate Products v02"):
- Modify the VBA (forms or modules) so that the progress meter "kicks in" once I click "Generate Master PK Table" (on form "F01_MainMenu).
- Please note that both versions (v01 AND v02) only includes 100 sample records; thus, this routine processes very quickly (~4 seconds).
- However, in my actual solution though, the "Generate Products PK Table" runs approximately for 2 to 3 minutes. Therefore, this progress meter will come in very handy.

My question:
- What modifications need to be made to "02B Generate Products v02 so that I get the progress meter working as well?

Thank you,
EEH
 

Attachments

  • 3 DBs.zip
    326 KB · Views: 75

MajP

You've got your good things, and you've got mine.
Local time
Today, 08:52
Joined
May 21, 2018
Messages
5,495
I did not develop the progress meter code, but have used this in several DBs. Here is the full demo. If you search this forum there are others.
@isladogs has one here
 

Attachments

  • MeterWithForms_v1.02.mdb
    432 KB · Views: 64

EEH_Help

Member
Local time
Today, 08:52
Joined
Feb 15, 2020
Messages
32
MajP -- thank you... copy all.

The attached sample file is very helpful. I'll try to integrate in the other process.

Thanks again for both the sample file and URL.

Cheers!
 

MajP

You've got your good things, and you've got mine.
Local time
Today, 08:52
Joined
May 21, 2018
Messages
5,495
That example is not mine and seems pretty old since it is in an.mdb. it would be simple to update with a more modern form.
 

EEH_Help

Member
Local time
Today, 08:52
Joined
Feb 15, 2020
Messages
32
Copy... thank you, MajP. I'll with lines will have to be integrated in my DB.

Cheers!
 

Users who are viewing this thread

Top Bottom