I need a progress counter for existing modues

dalebennett12349

New Member
Joined
Jul 21, 2010
Messages
9
Hey All,

I have 4 modues that delete unwanted email addressses from column A based on 4 different criteria. I need a numeric counter to show the progress of the deleting process.

I will share the VBA code for each module if you are willing tackle the project.

Also, how do I share the code in this forum?

THX

Dale
 

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.
The following is the code for the counter I need the most.

Sub Main()
Dim u1 As Long
Dim u2 As Long
Dim j1 As Long
Dim j2 As Long
Dim zN As Integer
Dim sht1 As String
Dim sht2 As String
Dim zS1 As String
Dim zS2 As String
Application.ScreenUpdating = False
sht1 = "Email addresses"
sht2 = "Names"
u1 = Sheets(sht1).Range("A1048576").End(xlUp).Row
u2 = Sheets(sht2).Range("A1048576").End(xlUp).Row
For j1 = 1 To u1
'If Sheets(sht1).Cells(j1, 1) = "" Then GoTo 111
zN = 0
For j2 = 1 To u2
zS1 = UCase(Sheets(sht1).Cells(j1, 1))
zS2 = UCase(Sheets(sht2).Cells(j2, 1))
If InStr(zS1, zS2) > 0 Then
zN = 1
Exit For
End If
Next j2
If zN = 0 Then
Sheets(sht1).Cells(j1, 1) = ""
zN = 0
End If
111
Next j1
Sheets(sht1).Range("A1:A" & u1).Sort Key1:=Sheets(sht1).Range("A1"), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal
Application.ScreenUpdating = True
End Sub
 
Upvote 0

Forum statistics

Threads
1,216,373
Messages
6,130,239
Members
449,568
Latest member
mwl_y

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top