B
Brigitte P
I'm on my end. I have a crosstab query with 2 row headings (a category and
subcategory) and then an EventDate which results in the column going Jan,
Feb, Mar ..... Dec. The query works fine, except it gives me all these empty
columns when I select less then 12 months. I know, it's an old problem.
I tried the code that Microsoft has published, downloaded the solution
database and copied the form and code from there, just changing to my form
and query names, but it doesn't work. I suppose this is because I have 2 row
headings instead one and deal with 12 date colums vs. the 9 they had
provided for. I added the extra columns, headers, totals to come to the
total 15 required, but that didn't help.
I then went to the site recommended by Duane Hookom with the "Mth0"
solution. This works as long as the underlying data is static, that is, as
long as I select the same number of month that I have allowed for in the
report. If I have Mth1, Mth 2, Mth 3 in the report and select the next time
6 month, 3 of them won't show up. I tried the Pivot Table solution, but that
is not what I need.
I'm about to pull out my hair; don't know how to do it, and don't know
enough about the Microsoft VBA to fix it.
The only solution I could find, have the end user put in the values for the
static colums (e.g., if they select from Aug - Oct they would have to type
Aug, Sep, Oct in the Column Headings query property. Is there a way to
prompt the user for this or do I need to make the crosstab query available
to her and hope that she doesn't forget or "mess up"?
Or, maybe a kind sould could copy the Microsoft solution, correct for my
extra head, col, tot rows, and email it to me. My end result needs to be:
Event Subevent Total Aug Sep Oct (or Jan, Feb,
Mar) (or whatever combination of month the user needs)
Fall Slippery 12 2 4 6
Medcial Flu 3 1 2
Many thanks in advance for any help.
Brigitte P
subcategory) and then an EventDate which results in the column going Jan,
Feb, Mar ..... Dec. The query works fine, except it gives me all these empty
columns when I select less then 12 months. I know, it's an old problem.
I tried the code that Microsoft has published, downloaded the solution
database and copied the form and code from there, just changing to my form
and query names, but it doesn't work. I suppose this is because I have 2 row
headings instead one and deal with 12 date colums vs. the 9 they had
provided for. I added the extra columns, headers, totals to come to the
total 15 required, but that didn't help.
I then went to the site recommended by Duane Hookom with the "Mth0"
solution. This works as long as the underlying data is static, that is, as
long as I select the same number of month that I have allowed for in the
report. If I have Mth1, Mth 2, Mth 3 in the report and select the next time
6 month, 3 of them won't show up. I tried the Pivot Table solution, but that
is not what I need.
I'm about to pull out my hair; don't know how to do it, and don't know
enough about the Microsoft VBA to fix it.
The only solution I could find, have the end user put in the values for the
static colums (e.g., if they select from Aug - Oct they would have to type
Aug, Sep, Oct in the Column Headings query property. Is there a way to
prompt the user for this or do I need to make the crosstab query available
to her and hope that she doesn't forget or "mess up"?
Or, maybe a kind sould could copy the Microsoft solution, correct for my
extra head, col, tot rows, and email it to me. My end result needs to be:
Event Subevent Total Aug Sep Oct (or Jan, Feb,
Mar) (or whatever combination of month the user needs)
Fall Slippery 12 2 4 6
Medcial Flu 3 1 2
Many thanks in advance for any help.
Brigitte P