Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Display all child records in a grid
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00430854
Message ID:
00430910
Views:
12
>Hi Ed,
> The form that I am having trouble with is the 1st form. It is a Wizard parent child form that contains 1 parent record (p.o id, order date, vendor's name)on top of the form, and all records (child records) in the grid(bottom of the form) that associated with the p.o id from the parents. This form is based on 2 view, purchase-order for parents and purchase-item for child records.
>
> From the 2nd form, i choose the p.o id, then lookup from the views, if they match, I want to display the parent record, all child records in the grid.
>
> My problem is I can display the parents, but with the child records(in the grid) only the first child record is displayed.
> How to display all child records in the grid?

I don't use any of the Wizard classes, so I can't recommend specific approaches using the app Wizard; I tend to create parameterized views for child grids; the p-view is set to select the child records whose po-id matches the parent record's po-id which is stored in the view parameter variable. The RowSource for the Child grid is set to the p-view, with a RowSourceType of Alias. Whenever the parent record is changed, I reset the RowSourceType of the child grid to None, requery the view, reset the RowSource to the p-view, reset the RowSourceType to Alias, and issue a Refresh against the grid.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Reply
Map
View

Click here to load this message in the networking platform