F
Finius Eetch
I'm having a problem getting the correct number of rows returned to me after
filtering.
I have the following lines in my Init Function.
ActiveSheet.AutoFilterMode = False
Range("A1", Cells(Rows.Count, 1).End(xlUp)).Resize(, 13).Select
total_nachos = Selection.Rows.Count
this returns the proper value to total_nachos, which is how many rows are in
my entire excel sheet a little over 20,000.
I dynamically build my filter list off column I (9) and need to store the
number of filtered tasks found when applying the filter. Here are the lines
I'm using when I apply the filter.
Selection.AutoFilter Field:=MyCategoryCol, Criteria1:=CatBuffer(2)
This applies the filter I want, and I see in the lower left the accurate
number of tasks. However, I cannot seem to get an accurate count returned to
the code - which is what I need, I get numbers that are way out of wack when
I populate my value.
Range("I1", Cells(Rows.Count, 1).End(xlUp)).Resize(, 13).Select
value=Select.Rows.Count
I'm sure it's something simple, I'm more of a VBA MS Project guy and this is
my first excel macro which has been a booming success with all my Project
knowledge, but the functions for returning ActiveSelections of rows/tasks are
different.
filtering.
I have the following lines in my Init Function.
ActiveSheet.AutoFilterMode = False
Range("A1", Cells(Rows.Count, 1).End(xlUp)).Resize(, 13).Select
total_nachos = Selection.Rows.Count
this returns the proper value to total_nachos, which is how many rows are in
my entire excel sheet a little over 20,000.
I dynamically build my filter list off column I (9) and need to store the
number of filtered tasks found when applying the filter. Here are the lines
I'm using when I apply the filter.
Selection.AutoFilter Field:=MyCategoryCol, Criteria1:=CatBuffer(2)
This applies the filter I want, and I see in the lower left the accurate
number of tasks. However, I cannot seem to get an accurate count returned to
the code - which is what I need, I get numbers that are way out of wack when
I populate my value.
Range("I1", Cells(Rows.Count, 1).End(xlUp)).Resize(, 13).Select
value=Select.Rows.Count
I'm sure it's something simple, I'm more of a VBA MS Project guy and this is
my first excel macro which has been a booming success with all my Project
knowledge, but the functions for returning ActiveSelections of rows/tasks are
different.