Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / New Users / March 2005

Tip: Looking for answers? Try searching our database.

Crosstab form?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
JOHN SMITH - 24 Mar 2005 17:16 GMT
Hi,

I have create a crosstab query that will have a constant number of rows
(machine names) and will have an indeterminate number of columns (days),

could be 10,11,12, 9, 8 columns

I would like to show this data either on a form  or report format.

Is there a way to add/eliminate fields on a form/report so that it will
match the number of columns on my table/query?

or another way to accomplish this?

Thank you all,

ciao
Duane Hookom - 24 Mar 2005 21:05 GMT
Decide on a number of columns and stick with it. Either that or make
separate forms/reports for each number of columns.

Then make your crosstab columns based on a "relative date" for instance
ColHead: "D" & DateDiff("d",[SaleDate], Date())
Set the Column Headings property to something like:
  D0, D1, D2, D3,...D10
The D0 column will display today's values.

Signature

Duane Hookom
MS Access MVP

> Hi,
>
[quoted text clipped - 13 lines]
>
> ciao
Craig Hornish - 24 Mar 2005 22:18 GMT
   If John's data can fit on one page with 12 colums then I would say yes -
make one report with 12 colums and hide the others as needed.
   But if you have to make multible reports, then you still can use the
same report.  In a crosstab report I have done I take the column of were the
data starts (not counting the grouping for rows) and use that info to
populate the colunms on the report about 8 that are not row information then
for the next grouping I have a modifier that adds to this to tell where I
should start the next set of data.
   I just have a form that gathers this information.  No need to have
multiple reports.

   If you have the Solutions database it has a good example of how to limit
the number of shown columns.

Craig Hornish
temp@cap-associates.com - so I can delete it when it becomes a spam magnet

"Think outside the box, because anything is possible."
"How long it will take or whether it requires divine intervention is another
issue"

> Decide on a number of columns and stick with it. Either that or make
> separate forms/reports for each number of columns.
[quoted text clipped - 22 lines]
>>
>> ciao
Duane Hookom - 25 Mar 2005 03:38 GMT
The "Solutions.mdb" solution is horrible. There is a much better and
flexible solution for dynamic (any number of columns) crosstab reports at
http://www.invisibleinc.com/divFiles.cfm?divDivID=4. If John thinks he
really needs the flexibility of any number of columns (rarely necessary)
than I would recommend this solution. It allows any number of derived
columns from 2 to 100s. It is also much faster and requires less code than
the Solutions.mdb.

Signature

Duane Hookom
MS Access MVP

>    If John's data can fit on one page with 12 colums then I would say
> yes - make one report with 12 colums and hide the others as needed.
[quoted text clipped - 43 lines]
>>>
>>> ciao
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.