Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Parent-Child Printing Problem
Message
From
24/03/2008 13:27:19
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Client/server
Title:
Parent-Child Printing Problem
Miscellaneous
Thread ID:
01304986
Message ID:
01304986
Views:
60
Hi Experts,

I use CursorAdapter subclasses in my data entry form class. Let us suppose I have just two CAs: INVOICEHEADER (Parent) and INVOICEDETAIL (Child).

For INVOICEHEADER, I pull out all the records, while for INVOICEDETAIL, I just requery for the detail records that the currenet INVOICEHEADER record is related to.

So, at any given time, whenever I change the record position of INVOICEHEADER, the data entry class will force the requery of INVOICEDETAIL. Works ok.

Now, printing out an invoice works fine - if ONE AT A TIME - since at any given time the current invoicedetail records have already been pulled. My problem lies in allowing the user to specify a range of invoice numbers to print as a batch!

Should I:

a. Just pull out ALL invoicedetail records, do a SET RELATION and SET SKIP TO Invoicedetail? (but this would not be 'sound' client-server pratice right?)

b. Go through a loop of actions for each INVOICEHEADER, like so:
- Go to first INVOICEHEADER in range
- Requery INVOICEDETAIL
- SET RELATION, SET SKIP TO InvoiceDetail
- PRINT...
- SET SKIP TO (deactivate SET SKIP)
- SKIP to next INVOICEHEADER record
- Requery INVOICEDETAIL .....

I still do not know if option B will work.

I hope there are better suggestions out there.

Thanks for any help.

Dennis
Next
Reply
Map
View

Click here to load this message in the networking platform