>Thanks Hilmar, I am still trying working on it.
>
>Dawa
Try p-views, you will be happy you did.
In the view designer, you need a filter condition. Let's say you need to "filter" a child table on the foreign key of the parent table. Your filter (in the "Filter" tab of the view designer) would look something like this:
ChildTable.ParentField = ?tnParentFieldIf you open the view in the form's DataEnvironment, make sure you set the property NoDataOnLoad to .T.
Then, define variable tnParentField, which may be either private or public. Private should be enough.
Give the variable a value, and requery() the view.
To change the view data to another parent key, repeat the last step for the new value.
I hope this is clear enough?
Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)