-
two details on reports
Is there a way to have 2 detail sections in a report. A client wants part
of the report in column format, then the second half in row format.
-
Re: two details on reports
David,
Perhaps this will get you going:
http://fox.wikis.com/wc.dll?Wiki~Mul...ProReports~VFP
--
Cindy Winegarden MCSD, Microsoft MVP
cindy.winegarden@mvps.org http://cindywinegarden.adsl.duke.edu
http://msdn.microsoft.com/vfoxpro http://foxcentral.net
"David W. Chapman Jr." <dwcjr@inethouston.net> wrote in message
news:3c1e131c$1@147.208.176.211...
> Is there a way to have 2 detail sections in a report. A client
wants part
> of the report in column format, then the second half in row format.
>
>
>
-
Re: two details on reports
Is there any way you could show me a screen shot of the report you are
talking about. I have the article book marked, but its not clicking right
now.
I also want to make sure we're on the same page.
"Cindy Winegarden" <cindy.winegarden@mvps.org> wrote in message
news:3c1e95e3$1@147.208.176.211...
> David,
>
> Perhaps this will get you going:
> http://fox.wikis.com/wc.dll?Wiki~Mul...ProReports~VFP
>
> --
>
-
Re: two details on reports
How to do a Multi-child FoxPro report:
*!* Create a cursor with fields from the parent and each of the
children
*!* Include a Field called RecordType
CREATE CURSOR ReportCursor (....)
*!* SCAN through the parent table
SCAN && FOR some criteria
*!* Get a clean set of all variables
SELECT ReportCursor
SCATTER MEMVAR MEMO BLANK
*!* Make the parent variables available for each row
*!* m.PrimaryKey is the parent table's PK
SELECT ParentTable
SCATTER MEMVAR MEMO
*!* Get matching records from Child!
SELECT Child1
m.RecordType = "Child1"
SCAN FOR Child1.ForeignKey = m.PrimaryKey
SCATTER MEMVAR MEMO
SELECT ReportCursor
INSERT INTO ReportCursor FROM MEMVAR
ENDSCAN
*!* Just in case,
*!* Clean out Child1 memvars
SELECT Child1
SCATTER MEMVAR MEMO BLANK
*!* Rescatter Parent memvars
SELECT Parent
SCATTER MEMVAR MEMO
*!* Get matching records from Child2
SELECT Child2
m.RecordType = "Child2"
SCAN FOR Child2.ForeignKey = m.PrimaryKey
SCATTER MEMVAR MEMO
SELECT ReportCursor
INSERT INTO ReportCursor FROM MEMVAR
ENDSCAN
ENDSCAN && Get next Parent record
*!* ==================== *!*
Example:
Store #1
Purchases
Purchase #1
Purchase #2
Purchase #3
Purchase Summary
Sales
Sale #1
Sale #2
Sale #3
Sales Summary
Store Summary
For your row-format - column format issue, try making a cursor with
Col1, Col2, Col3, Col4 and filling in the data using a loop that fills
in 4 across before appending a record. Then use the system above to
print either the row-format or the column format.
Finally, tell the customer that this is doable but difficult and
expensive. Ask him if it's worth the cost to him to pay you to make
this work, or if he would accept a different report format.
--
Cindy Winegarden MCSD, Microsoft MVP
cindy.winegarden@mvps.org http://cindywinegarden.adsl.duke.edu
http://msdn.microsoft.com/vfoxpro http://foxcentral.net
"David W. Chapman Jr." <dwcjr@inethouston.net> wrote in message
news:3c1e9cf1$1@147.208.176.211...
> Is there any way you could show me a screen shot of the report you
are
> talking about. I have the article book marked, but its not clicking
right
> now.
> I also want to make sure we're on the same page.
>
> "Cindy Winegarden" <cindy.winegarden@mvps.org> wrote in message
> news:3c1e95e3$1@147.208.176.211...
> > David,
> >
> > Perhaps this will get you going:
> > http://fox.wikis.com/wc.dll?Wiki~Mul...ProReports~VFP
> >
> > --
> >
>
>
>
-
Re: two details on reports
>
> For your row-format - column format issue, try making a cursor with
> Col1, Col2, Col3, Col4 and filling in the data using a loop that fills
> in 4 across before appending a record. Then use the system above to
> print either the row-format or the column format.
>
> Finally, tell the customer that this is doable but difficult and
> expensive. Ask him if it's worth the cost to him to pay you to make
> this work, or if he would accept a different report format.
>
The problem is that the items in the colums might have 5 columns, but the
itsm in rows might have 10 or more rows. I think I probably need to play
with it for a while. Thanks for the help so far.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks