Hi,
I just want to know if its possible to do a macro wherein I can select the dates to be read in my report. For instance, I have a Table (below) where column A is the Date, column B is the name of Agents, Column C is the Section and the Column D is the Error Category. A window will pop-up where in I can select the date range the the macro will read.
Usually I have a monthly report and I keep on sorting and filtering the Table if my boss is asking for a weekly report. The report usually are:
How many errors does each Agents received on this particular dates?
What section has most errors in this particular dates?
What are the most common errors in this particular dates?
What are the most common error of each agents in this particualr dates?
What are the most common errors of each section in this particular dates?
[table style="border-collapse: collapse; width: 356pt;" width="473" border="0" cellpadding="0" cellspacing="0">
[tbody]
[tr style="height: 15pt;" height="20">
[td class="xl65" style="height: 15pt; width: 79pt;" width="105" height="20">Date[/td]
[td class="xl66" style="border-left: medium none; width: 74pt;" width="98">Name[/td]
[td class="xl66" style="border-left: medium none; width: 89pt;" width="118">Section[/td]
[td class="xl66" style="border-left: medium none; width: 114pt;" width="152">Error Category[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Peter[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Delta[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Name[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Jack[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Age[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Mike[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Bravo[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Address[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Cris[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Name[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Sam[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Charlie[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Name[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Noah[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Charlie[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Name[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">21-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Jack[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Charlie[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Name[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">25-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Mike[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Charlie[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Comment[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">25-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Cris[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Delta[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Comment[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">25-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Peter[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Comment[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">25-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Jack[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Bravo[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Comment[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">25-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Mike[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Name[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">25-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Cris[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Delta[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Address[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">29-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Jack[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Address[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">29-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Mike[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Bravo[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Age[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">29-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Cris[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Age[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">29-Nov[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Peter[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Alpha[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Age[/td]
[/tr]
[/tbody]
[/table]
[table style="border-collapse: collapse; height: 340px;" width="476" border="0" cellpadding="0" cellspacing="0">
[tbody]
[tr style="height: 15pt;" height="20">
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">Hope you have an answer to my problem.
Thank you in advance![/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[tr style="height: 15pt;" height="20">
[td class="xl64" style="height: 15pt; border-top: medium none;" height="20">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[td class="xl63" style="border-top: medium none; border-left: medium none;">[/td]
[/tr]
[/tr]
[/tbody]
[/table]
Software/Hardware used:
MS Excel
ASKED:
November 30, 2010 4:18 PM
UPDATED:
December 2, 2010 7:03 AM
Hi,
Sorry for the mess on my prior question…
Hi,
I just want to know if its possible to do a macro wherein I can select the dates to be read in my report. For instance, I have a Table (below) where column A is the Date, column B is the name of Agents, Column C is the Section and the Column D is the Error Category. A window will pop-up where in I can select the date range the the macro will read.
Usually I have a monthly report and I keep on sorting and filtering the Table if my boss is asking for a weekly report. The report usually are:
How many errors does each Agents received on this particular dates?
What section has most errors in this particular dates?
What are the most common errors in this particular dates?
What are the most common error of each agents in this particualr dates?
What are the most common errors of each section in this particular dates?
Date Name Section Error Category
21-Nov Peter Delta Name
21-Nov Jack Alpha Age
21-Nov Mike Bravo Address
21-Nov Cris Alpha Name
21-Nov Sam Charlie Name
21-Nov Noah Charlie Name
21-Nov Jack Charlie Name
25-Nov Mike Charlie Comment
25-Nov Cris Delta Comment
25-Nov Peter Alpha Comment
25-Nov Jack Bravo Comment
25-Nov Mike Alpha Name
25-Nov Cris Delta Address
29-Nov Jack Alpha Address
29-Nov Mike Bravo Age
29-Nov Cris Alpha Age
29-Nov Peter Alpha Age
Are you asking how to create a macro to enter the dates range, or how to create the reports that will answer all those questions, or both ?
That is the kind of task that would be much more easier using a database instead of spreadsheet. Have you considered that option ?
Hi Carlosdl,
Both, actually I am currently using formula in excel but I’m thinking if its possible for macro. I haven’t thought of using database cause I don’t know how to do it while in macro I can understand it a little bit.
If you provide the formulas you are currently using, it should be easier to translate them into a macro.
I have 3 columns that counts all the Agents Name, the Agents Name and the Error, Error and the Section. The formula is…
Agents Name
=B2 (Column B)
Agents Name and the Error
=B2&D2 (Column B&D)
Error and the Section
=D2&C2 (Column D&C)
so on and so forth….And then I have a Table wherein the first column is the list of agents name. To count all the agents error I simply use this formula..
IF(A1=”",”",IF(A41>0,COUNTIF($AI$3:$AL$1555,A41))) SO ON AND SO FORTH…