Free Microsoft Excel 2013 Quick Reference

Count line numbers Results

When using auto filters. Sorting by (1) Date to Date then by (2) Product ID, I show visible rows that I can total the columns (Total Weight) that excludes non visible lines using =SUBTOTAL(9,Q10:Q1000). That Works.

But additionally I need to count ONLY the number of items in the visible column that contain the text of various Truck Companies to get a count of the number of trucks shipped. If I try to count the non blank cells of the visible cells it counts all the hidden cells too.

How do I count just the number of visible cells containing text in a column when in auto filter? OR count someother column containing numbers or text for the purpose of getting a count of the visible lines that would get the same result (number of shipments)?


I've got a question about pivot tables and I hope you can help me out.

When you look at the black pivot it shows me the count of 'Classification 1', with the count of the succeeding 'Classification 2'.
So for example for line 1 and 9:

Number Classification 1 Classification 2
1 Type A Type B
9 Type A Type C

Gives me a pivot table:
Classification 1 Classification 2 Total
Type A
Type B 1
Type C 1
Type A Total 2

'Type A' is chosen two times in 'Classification 1'. Whereby 'Type B' and 'Type C' are both succeeding 'Type A' one time.

When we look at the rest of the table:
3 Type D
4 Type B Type C
5 Type C
6 Type C
7 Type B
8 Type B Type D
9 Type A Type C

We can see that 'Type D' is chosen once as 'Classification 1' at line 3. The Pivot for 'Type D' looks like this:
Type D (blank) 1
Type D Total 1
Whereby there is one 'Type D' chosen as 'Classification 1' and there is no 'Classification 2' specified.

Type D is also chosen as a 'Classification 2' at line 8.
At the Pivot this Classification is shown as a succeeding classification of Type B:

Type B
Type C 2
Type D 1
(blank) 1
Type B Total 4

That is not what I want.
I want to see that 'Type D' is chosen 2 times (line 3 and 8).
That Type C is chosen 5 times (line 2,4,5,6,9)
Type B 5 times and Type A 2 time.
You can see what I mean in the Blue/Orange table. I would like to see that the Classification 1 and 2 field are combined into one total classification.

And because I use this Pivot table with a large database, it is important that this information is in a 'Pivot Field'.
So that I can see:

Count of number of:
People etc.

Hi wizards

I have a sales ledger which shows invoice no, customer name, invoice value, and amount paid, I wish to produce a summary that shows a one line entry for customers that have unpaid. The problem I have is if a customer has more than one invoice unpaid, I get an entry for each invoice.

I also want to count the number of customers, on the sales ledger, which sounds easy enough but again I can't get round duplicates


Best way to explain this question is by example
I have a column of numbers

Column X

The biggest gap in between the number 1 occurring is 6 times as bold above. How can i using excel formula or VBA highlight this, especially in a much larger range of data (like 15000 Lines)

We have an inherited SS which has many autofilters set. Some of them, when activated, display the number of filted lines on the grey bar at the bottom left of the screen and some do not, eg 245 of 27485 records found. How do we set this function?

I am trying to count values in one column if there is a value in the same row in another column. Complicating things, the count is in a separate worksheet in the same workbook. Sorry in advance if this explanation is confusing, the tables themselves contain some sensitive data that I can't publish, so I have to try to be careful about what I disclose.

I have a spreadsheet that consists of a report worksheet and numerous other worksheets (all based on a common template but containing different data) that feed the report.

The report is a summary of data from a number of other worksheets (all in the same file). Each row in the report corresponds to a different worksheet. The first column of the report contains the names of all the tabs, and I'm using INDIRECT to key the formulas in all the other columns, which basically just tabulate some counts, like so:

In this example, B4 is the first cell of the first row in the formatted table, which contains the name of the first data
worksheet, and the range T9:T500 contains a list of dates corresponding to when the person indicated in a different column in
that row performed a particular task.  The result (which works fine) is a count of all the cells that contain a date,
indicating that the task is complete (as opposed to an empty cell, which is not counted, and means that the task is not
complete).  From this I can determine how many lines (tasks) are complete.

The last feature of the report I would like to incorporate correlates the value in one column (a department name) with the date previously mentioned. In plain English, the correlation means to me that, if there's a date in the last column, a person completed that task on behalf of the department. Put another way, there are half a dozen or so departments, and I'm trying to get a count, by department, of tasks that have been completed. I can already count the breakdown of tasks by department, but I need to now figure out by department how many are complete (and by inference, how many are incomplete).

So if I have the following sample data, how would I go about creating a formula that increments the count based on these criteria:
If the value in column N is "ABC" then...If the value in column T of the same row is not empty, increment the count.
Column N:
N1 Human Resources
N2 Human Resources
N3 Tech Support
N4 Human Resources
N5 Tech Support
N6 Customer Billing

Column T:
T1 -empty-
T2 5/17/2010
T3 -empty-
T4 5/20/2010
T5 -empty-
T6 6/29/2010

So, for instance, I need to be able to specify "Human Resources" as the match, and I would expect it to return a count of "2" since there are two entries in Column T that are not empty that correspond to "Human Resources" in Column N.

If someone is able to help me figure out how to just do the counting, I should be able to work backwards to incorporate the worksheet references using INDIRECT and all that stuff. I've tried using combinations of COUNT, IF, COUNTIF and VLOOKUP but all I can ever get it to do is evaluate to 1 or 0, not a count.

There may be an easier way to do this with pivot tables, but I haven't been able to figure out how to get that working correctly either.

Thanks in advance for any help.


Hi All,

Relative Excel 2007 novice here. I am trying to set up a spreadsheet which allows people to sort and highlight groups of numbers based on their preferences.

I first set up a macro to sort the data columns into the appropriate format (by % of sales).

I want the user to be able to input 5 numbers (which would be the # size of 5 groups), and excel to highlight and divide one column based on that input. I'm thinking (in pseudo-code) along the lines of:

x1 = 5, x2 = 10. If(Row >/= x1 and </= x2, Highlight Cells Red). And so forth.

Is there a way to do this using conditional formatting, or something? Attached is a basic rubrik that I am working with.

I will do my best to explain what I am having a problem with....

I have a sheet that shows planned production at different work stations. Some of the work stations are listed more than once because sometimes they run more than one product in the same day.
Every other line is the planned production and the others are filled in after as the actual production
I have a sumproduct formula right now that looks if the line is considered planned production and then if there is a number greater than 0 planned on that day. The idea is to tell me the number of Stations scheduled to run that day.

Here is my problem- if a station is running two different products it gets counted twice.
I am trying to find a way that once a station is counted it only gets counted once even though they are on seperate lines.
Attached is an example of what I have with the formula and below that is what I am looking for


I'm looking for some help on how to use the COUNTBLANK command (or some other function that will accomplish the same thing) to count the number of blank cells in a named range that is NOT continuous.

Because (I assume) Countblank can not be used to count multiple ranges in one command it is returning #VALUE! to my cell

I would be looking to count the blank squares in the A column if the B column looks something like this

Blue Circle
Blue Square
Blue Triangle
Green Circle
Green Square
Green Triangle
Red Circle
Red Square
Red Triangle
Yellow Circle
Yellow Square
Yellow Triangle

The user would then enter a 1 in the A1:A12 column indicating if they are using that color/shape combo

I would then have a named range that includes all of the blue shapes (A1:A3) named Blue one that inlcudes all the green shapes (A4:a6) named Green etc and then one named "circle" that includes all the circles (A1,A4,A7,A10)

I then want to count the number of blank squares in the circle range using the named range.

It's obviously impossible to move all the shapes together because then the colors are seperated.
What I've done for the moment is =COUNTBLANK(A1)+COUNTBLANK(A4)+COUNTBLANK(A7)... etc
however because in the real file the list is potentialy hundreds of lines long this is something of a pain, and in the future when I add Beige circles and green Hexagons or whatever I would have to add a new COUNTBLANK function for every new shape, and it could be problamatic to see at a glance if everything is adding up correctly.

after a google search I found a site claiming
would work, however it is returning the same error

another solution I've somewhat thought about using, is on a seperate hidden sheet make a line that would look like

Circle =A1 =A4 =A7 etc
and than just naming THAT the range, however it somewhat still results in my having to go back everytime I update or move something and adjust it accordingly.

Any help or suggestions anyone has would be greatly appreciated

I am using Excel/Office 2003. How do I count the lines in a specific Column that contain data?


Hi all

It's been a long time since contacting this newsgroup. Thanks to those
who helped my in the past......(only a couple of times....don't want to
abuse your kindness)

This time the challenge is way beyond my sphere of knowledge.......don't
even know if what I'm asking is possible ???

The subject sheet is relatively is nine columns wide
and hundreds of lines long. mmmm how do I go on from here?? How about
just writing it in semi English and see if we can get an Excel formula that
may work.....

Nine columns wide, hundreds of lines long..........from this sheet the
challenge is to extract information something like this......

Count the number of lines if the line meets the following criteria.......

Column 1 = "1350" and Column 2 = either "APPROVED" or "REQUAL PENDING" and
Column 5 = "E" and Column 6 = "MM"

The rest of my sheet has been completed with other formula to give me
information........this is the final step to make the information useful.

Thanks in advance


I have a spreadsheet of tasks, each of which has a field for 'Start Date' and a field for 'End Date'. I would like to generate a graphical representation of how many of these tasks would be going on simultaneously. So, for example, a line graph would have the number of tasks in progress on the y-axis and the date/time on the x-axis.

What is the best way to accomplish this? I know this forum is primarily for Excel 2007, but I'm still using 2003.

Any help would be greatly appreciated.


I have a set of data that tracks the number of changes to a file over
time. I want to show a line chart that I can use to visually locate a
file with a low churn rate. "Low churn rate" could either mean "Has
changed a lot in the past but hasn't changed in a while" or it could
mean "has the lowest number of changes happening to it right now."

The purpose of this is that we have a set of operations we want to
perform on files, but only if they are fairly stable and either aren't
getting changed often, or haven't changed in a while.

My data is something like this:


I'm having trouble wrapping my mind around how exactly I want this to
look graphically. I definitely want the X axis to be time and I want
one line in the chart per FileID, but I'm not sure about how to
configure the Y axis to reach my goal of allowing me to visually pick
out a "low churn" file.

If I were to just have "Count of changeddate per fileid" as the Y axis,
then all I get is a flat horizontal set of rows which just tells me a
file has churned a certain amount, it doesn't tell me if it's churning
less now than it was a month ago.

If I make it a bar chart with the X axis of FileID and the Y axis
ChangedDate, with the data portion being Sum of FileID, that *kind of*
gets me what I want, because you can visually pick out the FileIDs that
have a lot of bars next to them. The problem with this is that I expect
to have hundreds if not thousands of FileIDs at some point, so I need
something to help me visually pick those out... and perhaps a line
chart isn't it, but it seems closer than anything else.

Any pointers much appreciated, thanks.

Hello to all the Excel Gurus by here.
I'm having a what-seems-to-be an easy problem I can't solve.
I've got an array with, in colums, dates, and on each lines, sport teams. I'd like to know, for each team, how many match they won.


Explanation :
ColA : Team names
Col B to D : Scores. On 18th of February, teams Tm1 and Tm6 played against Tm3 and Tm5, and lost 10-13. on 25th of February, Tm2 and Tm3 lost against Tm1 and Tm4.
ColE : I would like it to fill automatically with the numbers I've calculated by hand this time : Tm1 won only on 25th Feb, for example; Tm4 won 2 times, etc...

I've tried some things with BDMAX, SumIf, SumProduct, but didn't succeed

Can anyone find me a formula solution? (I could do it with VBA, but I want to share those array with some corporative folks with sometime weird security settings that could mess up with the alerts)

Thank you in advance for your help; please don't hesitate to ask if anything is not clear.

Hi Everyone, HELP!

I need to format data where it can be uploaded into a excel spreadsheet for automatic invoicing.

So far I have figured out that I can get close to what I need by using Data: Subtotal. If I sort the data by particapant name and then count the items that gives me part of the information where I need it.

The two things that I need to do now in column A I need the dealer code to copy down to the count line.

The second thing is I need a way to concatate the cells in row L into the count line. Example (mod. 3, mod. 4, mod 6, mod 7)

I know how to do this manually however this report is usually 2000 line items and it would take more time to manually make these changes to each group.

To sum it up I have a large spreadsheet that I need to total by participant and I need the following information in the total line. (I only need the total line to cut and paste.)

Dealer code,Participant Name, all off the mod numbers in one field and the count of mods.

Some type of summary report might work. See data for clarification.

A K L N (rows)
Dealer Participant Mod. Cost
Code Name

F24DB GREGORY MOAN Mod. 17 $15.00
F24DB GREGORY MOAN Mod. 21 $15.00
F24DB WADE SNOW Mod. 17 $15.00
F24DP MICHELLE MILLS Mod. 2 $15.00
F24DP MICHELLE MILLS Mod. 3 $15.00
F24DP MICHELLE MILLS Mod. 4 $15.00
F24DP MICHELLE MILLS Mod. 5 $15.00
F24DP MICHELLE MILLS Mod. 6 $15.00
F24DP MICHELLE MILLS Mod. 7 $15.00

Hopefully I haven't totally confussed everyone.

Thanks Lostinformulas

hi all,

I may be completely off track (if so, please put me right) but I think that sumproduct should/will provide a solution as I try to count unique occurences w/in data after checking that it matches multiple criteria (converted to single cells as strings)...

I've had a look at Chip's duplicate/unique items & his array formulae page but can't seem to adapt them for my purpose.

In an extracted (from AS400 to Excel) Stock on Hand Report of about 4000 lines of cheese, the stock is "uniquely" identifed by Location (double alpha), sLot (short Lot, provides factory (single alpha) & date (ddmmy) of manufacture), and Material (six digit & single alpha).
However, due to an unforeseen programming issue, since resolved, a number of lines were created with duplicate Lots (single alpha for end market, sLot, & 3 letter code for end use) mapped against a multiple Materials (should be unique to a single material).
The programmer's may develop a report in the future, but in the mean time...

What is a formula I can use to get a count of the multiple materials based on stock that has the same Location & sLot(that can be expanded out to cover 4000 ish rows)?

The examples below should give answers of 2 & 3 respectively:
Loc&sLot LocMat&sLot
IPC16080 IP104256EC16080 (#1)
IPC16080 IP106101EC16080 (#2)
IPC16080 IP106101EC16080 (#2)
IPC17080 IP106101EC17080

Loc&sLot LocMat&sLot
IPC16080 IP104256EC16080 (#1)
IPC16080 IP101601EC16080 (#2)
IPC16080 IP106101EC16080 (#3)
IPC17080 IP106101EC17080

My attempts so far:
Count of Different Mat's based on same Loc&sLot
2 =SUMPRODUCT(($R$2:$R$5=R2)*1,($V$2:$V$5<>V2)*1)
#VALUE! =SUMPRODUCT(SUMPRODUCT(($R$2:$R$5=R2)*1),($V$2:$V$5<>V2)*1)

Thanks in advance,
Rob Brockett
Always learning & the best way to learn is to experience...

Basically I have 2 columns each with a list of dates in no particular order (and containing blank cells too), one planned date column and one actual date column.

What I need to do is plot this on a graph, and since the number of dates has no set limit and I dont want to have to plot maybe 100 dates on the x axis, so i want to group them by week before plotting them, i.e. 10 dates for week ending 10th jan, 25 dates for week ending 17th jan etc

I have a pivot table that counts how many of each date occurs, i.e. 10 x 2nd jan, 7x 3rd jan etc etc but it does not split them into weeks.

im sure theres an easyish way of doing it so i can get the 2 lines on the graph for no. of planned dates each week and no. of actual dates each week, i just cant see it.


This is the data that I have - what I want to count is how many times each
number 2 through 25 are on the same lines as #1

Example - just using the first five rows 7,16,20,25 would all show a 1 and
the remaining numbers would all show 0

Likewise how many times each number 1, 3-25 are on the same line as #2

Please help

24 2 6 13 15
17 3 22 4 14
16 25 1 7 20
5 23 18 21 10
11 19 8 12 9

1 20 21 2 4
8 17 15 18 25
22 12 10 6 7
9 16 13 14 24
23 5 3 19 11

7 22 21 8 12
13 9 17 15 5
24 6 4 25 23
18 1 20 10 3
14 11 2 16 19

7 8 5 24 6
25 4 9 17 1
15 10 23 3 21
19 18 16 22 13
12 14 11 20 2

6 24 25 9 18
20 15 19 23 22
10 13 12 5 16
3 21 14 11 17
2 7 4 1 8

9 22 10 24 21
16 3 6 19 13
2 18 7 17 23
15 1 12 4 11
20 5 8 14 25

17 19 24 10 12
18 14 6 1 23
25 21 13 11 7
16 15 8 3 4
9 20 2 22 5

18 4 11 10 14
17 6 16 21 15
13 23 8 12 20
1 5 22 25 19
24 3 9 7 2

6 20 17 8 18
22 11 24 1 13
3 25 12 2 10
5 4 23 9 16
7 15 14 19 21

8 10 17 1 3
5 16 11 6 20
12 18 25 15 14
13 2 19 7 4
21 9 22 23 24

4 7 3 17 8
10 14 5 11 15
9 6 20 24 22
25 13 16 2 21
1 23 19 12 18

8 3 7 2 17
16 6 24 13 19
15 4 14 18 11
12 9 20 5 22
21 25 10 23 1

19 7 3 22 20
14 12 15 16 5
11 17 4 10 2
6 18 13 25 24
23 21 1 8 9

21 14 22 13 6
4 5 18 20 12
15 24 17 11 2
19 16 1 9 10
7 8 25 23 3

I need a formula that will count 10000 lines of various parts in column A, then look at the shipped date in column H then count these up to populate cells like this.

part number total 10-12 months ago 7-9 months ago 4-6 months 0-3 months
x123 24 12 6 5 1

bv256 50 25 15 2 8

frd65 116 58 0 38 20

I know this would be achievable in a pivot table, but i need the formula in spreadsheet in order to apply further values in order to forecast uplift or downturn in slaes/volume capcity etc

many thanks


Hi All,

I have been looking at a way to add event handlers to control items I have dynamically created at run time. The userform I have created acts like a wizard for the end user and allows them to streamline their process by having pre-defined information stored within a sheet that will pull though when certain information has been selected. The number of required control items is unknown so this would be the preferred option for me. Again, any help on where I may have gone wrong (Code below) would be much appriciated.

The focus area on which I appear to be having the issue is within the "Addline" procedure (Paticularly the lines :Dim LR As New LineRemover, Set LR.Control = Cheb(iCount)).

The Cheb(iCount) control value passes a "False" value and does not update the useform when I select the paticular item.

Apologies if my code is a bit messy!

My Userform Code
Option Explicit

Private Cmd(1000) As MSForms.CommandButton
Private Lbl(1000) As MSForms.Label
Private tb(1000) As MSForms.TextBox
Private Comb(1000) As MSForms.ComboBox
Private Cheb(1000) As MSForms.CheckBox
Private Linecol(50) As Collection

Public _
    iStandard_Height, _
    iRatetype_Left, _
    iUnits_Left, _
    iUnittype_Left, _
    iPayperunit_Left, _
    iBillperunit_Left, _
    iPurchaseOrder_Left, _
    iDescription_Left, _
    iTotalpay_Left, _
    iTotalbill_Left, _
    iGrossmargin_Left, _
    iRemoveline_Left, _
    iRatetype_Width, _
    iUnits_Width, _
    iUnittype_Width, _
    iPayperunit_Width, _
    iBillperunit_Width, _
    iPurchaseOrder_Width, _
    iDescription_Width, _
    iTotalpay_Width, _
    iTotalbill_Width, _
    iGrossmargin_Width, _
    iRemoveline_Width _
As Integer

Public _
    iFirstline_Top, _
    iline_gap, _
    iCount _
As Integer
Private Sub Setboxvalues()

'///Sets the first line value and gaps between each line
iFirstline_Top = 174 'Should be 192 but removed as the gap brings it back to the correct value
iline_gap = 18

'///Sets the standard height
iStandard_Height = 14.25

'///Sets the left value for each line item
iRatetype_Left = 6
iUnits_Left = 138
iUnittype_Left = 180
iPayperunit_Left = 234
iBillperunit_Left = 294
iPurchaseOrder_Left = 354
iDescription_Left = 432
iTotalpay_Left = 522
iTotalbill_Left = 594
iGrossmargin_Left = 666
iRemoveline_Left = 738

'///Sets the width value for each item
iRatetype_Width = 126
iUnits_Width = 36
iUnittype_Width = 48
iPayperunit_Width = 54
iBillperunit_Width = 54
iPurchaseOrder_Width = 72
iDescription_Width = 84
iTotalpay_Width = 66
iTotalbill_Width = 66
iGrossmargin_Width = 66
iRemoveline_Width = 12

'///Sets the initial line number
iCount = 1

End Sub
Private Sub Addline(RateType, Units, UnitType, PayperUnit, BillperUnit, PurchaseOrder, Description, TotalPay, TotalBill,

Engine.Alerts False

Set Linecol(iCount) = New Collection
    Createline "COMBO", iCount, (iFirstline_Top + (iline_gap * iCount)), iRatetype_Left, iRatetype_Width,
iStandard_Height, "=Rates", True, RateType, "Rates"
        Linecol(iCount).Add Comb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iUnits_Left, iUnits_Width, iStandard_Height,
"Blank", True, Units, "Units"
        Linecol(iCount).Add tb(iCount)
    Createline "COMBO", iCount, (iFirstline_Top + (iline_gap * iCount)), iUnittype_Left, iUnittype_Width,
iStandard_Height, "=Units", True, UnitType, "UnitType"
        Linecol(iCount).Add Comb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iPayperunit_Left, iPayperunit_Width,
iStandard_Height, "Blank", True, PayperUnit, "PayPerUnit"
        Linecol(iCount).Add tb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iBillperunit_Left, iBillperunit_Width,
iStandard_Height, "Blank", True, BillperUnit, "BillPerUnit"
        Linecol(iCount).Add tb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iPurchaseOrder_Left, iPurchaseOrder_Width,
iStandard_Height, "Blank", True, PurchaseOrder, "PurchaseOrder"
        Linecol(iCount).Add tb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iDescription_Left, iDescription_Width,
iStandard_Height, "Blank", True, Description, "Description"
        Linecol(iCount).Add tb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iTotalpay_Left, iTotalpay_Width,
iStandard_Height, "Blank", False, TotalPay, "TotalPay"
        Linecol(iCount).Add tb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iTotalbill_Left, iTotalbill_Width,
iStandard_Height, "Blank", False, TotalBill, "TotalBill"
        Linecol(iCount).Add tb(iCount)
    Createline "TB", iCount, (iFirstline_Top + (iline_gap * iCount)), iGrossmargin_Left, iGrossmargin_Width,
iStandard_Height, "Blank", False, GrossMargin, "GrossMargin"
        Linecol(iCount).Add tb(iCount)
    Createline "CHEB", iCount, ((iFirstline_Top + 1) + (iline_gap * iCount)), iRemoveline_Left, iRemoveline_Width,
iRemoveline_Width, "Blank", True, False, "RemoveLine"
        Linecol(iCount).Add Cheb(iCount)
        '//Adds event changer
            Dim LR As New LineRemover
            Set LR.Control = Cheb(iCount)

    Form_Timesheet_Wizard.Height = Form_Timesheet_Wizard.Height + iline_gap
    iCount = iCount + 1

Engine.Alerts True

End Sub
Private Sub FormRefresh()

Dim Finalrowcount As Integer
Dim rSearch As Range
Dim cl As Variant

Engine.Alerts False

'///Adds the payment to field
Finalrowcount = Range("F65000").End(xlUp).Row
Set rSearch = Range("F8", "F" & Finalrowcount)
    For Each cl In rSearch
        If cl.Value = Cb_Candidate Then
         Cb_Paymentto.Value = cl.Offset(0, 1).Value
        Else: End If
    Next cl

'///Looks for all the available saved rate fields
ThisWorkbook.Sheets("Rate Card").Activate
Finalrowcount = Range("B65000").End(xlUp).Row
Set rSearch = Range("B8", "B" & Finalrowcount)
    For Each cl In rSearch
        If Cb_Candidate = cl.Offset(0, 1).Value And Cb_Client.Value = cl.Offset(0, 0).Value Then
            Addline _
              cl.Offset(0, 2).Value, _
              "", _
              cl.Offset(0, 3).Value, _
              cl.Offset(0, 5).Value, _
              cl.Offset(0, 6).Value, _
              cl.Offset(0, 4).Value, _
              cl.Offset(0, 7).Value, _
              "", _
              "", _
            '///Adds the consultant assigned to the rate line
            Cb_Consultant.Value = cl.Offset(0, 8).Value
        Else: End If
    Next cl

Engine.Alerts True

End Sub
Private Sub Createline(cType, Count, Top, Left, Width, Height, Rowsource, Enabled, Value, Objname)

Select Case cType
    Case Is = "TB"
        Set tb(iCount) = Form_Timesheet_Wizard.Controls.Add("Forms.Textbox.1", Objname & iCount)
            With tb(iCount)
                .Top = Top
                .Left = Left
                .Width = Width
                .Height = Height
                .Borderstyle = fmBorderStyleSingle
                .Specialeffect = fmSpecialEffectFlat
                .Enabled = Enabled
                .Value = Value
            End With
    Case Is = "CMD"
    Case Is = "LB"

    Case Is = "COMBO"
        Set Comb(iCount) = Form_Timesheet_Wizard.Controls.Add("Forms.Combobox.1", Objname & iCount)
            With Comb(iCount)
                .Top = Top
                .Left = Left
                .Width = Width
                .Height = Height
                .Borderstyle = fmBorderStyleSingle
                .Specialeffect = fmSpecialEffectFlat
                .Rowsource = Rowsource
                .Value = Value
            End With
    Case Is = "CHEB"
         Set Cheb(iCount) = Form_Timesheet_Wizard.Controls.Add("Forms.Checkbox.1", Objname & iCount)
            With Cheb(iCount)
                .Top = Top
                .Left = Left
                .Width = Width
                .Height = Height
                .Specialeffect = fmSpecialEffectFlat
                .Value = Value
            End With
Case Else: End Select

End Sub
Private Sub Cb_Candidate_afterupdate()
End Sub
Private Sub Cb_Client_afterupdate()
End Sub
Private Sub Label1_Click()
    Addline "", "", "", "", "", "", "", "",
"", ""
End Sub
Private Sub UserForm_Initialize()
End Sub
My Class Module Code Titled "LineRemover"
Option Explicit
Public WithEvents tbxCustom1 As MSForms.CheckBox 'Custom Checkbox
Public Property Set Control(tbxNew As MSForms.CheckBox)
Set tbxCustom1 = tbxNew
End Property
Private Sub tbxCustom1_Change()
    MsgBox "You changed the value of: " & tbxCustom1.Name
End Sub

No luck finding an answer? You could always try Google.