My DB consists of two tables - a Parent table named �CW_Clients� & a Child table named �CW_Line_Items�. These are linked as a 1:M set via a �ClientNumber� field and index on the common field in both tables.
The parent table has a numeric field called �Billing Rate�, and the child table has a numeric field called �Cost_Per_Hour�. Both the parent record, & the corresponding child (embedded browse) records, are viewed through the one form, and data is entered through this same form. An invoice is then formed and printed from that child line-item record data, along with its relevant parent record data.
When wanting to enter data into the child line-items record/fields, I simply want the child �Cost-Per-Hour� field, to take the data from the corresponding parent predetermined or preset �Billing-Rate� field (and which is already open, saved and viewable on the form as the current record), and make it available as the default value to the �Cost-Per-Hour� field. That is, if the �Billing-Rate� rate in the parent record is say $120.00, I want that $120.00 to be set and offered as the default in the child �Cost-Per-Hour� field/record.
However when going to Field Rules for the Child table and �Cost-Per-Hour� field, and then trying to set a simple data entry default expression for the field, the �F2 � Select Field� option in the expression builder only allows me to select fields from the child table, and not the parent table. No doubt there is a good A5 reason for this, but that�s beyond my knowledge and ability.
I�ve tried the �lookup� system in the field rules, but that is not really satisfactory; nor is many other ideas I�ve tried. I�m sure this should not be too hard for you very clever A5 gurus out there, and would seem to be a reasonably simple requirement of A5, but A5 does not seem to want to easily allow it, and it�s beyond me at the moment. I would greatly appreciate any and all help on this.
Many thanks
adooke
The parent table has a numeric field called �Billing Rate�, and the child table has a numeric field called �Cost_Per_Hour�. Both the parent record, & the corresponding child (embedded browse) records, are viewed through the one form, and data is entered through this same form. An invoice is then formed and printed from that child line-item record data, along with its relevant parent record data.
When wanting to enter data into the child line-items record/fields, I simply want the child �Cost-Per-Hour� field, to take the data from the corresponding parent predetermined or preset �Billing-Rate� field (and which is already open, saved and viewable on the form as the current record), and make it available as the default value to the �Cost-Per-Hour� field. That is, if the �Billing-Rate� rate in the parent record is say $120.00, I want that $120.00 to be set and offered as the default in the child �Cost-Per-Hour� field/record.
However when going to Field Rules for the Child table and �Cost-Per-Hour� field, and then trying to set a simple data entry default expression for the field, the �F2 � Select Field� option in the expression builder only allows me to select fields from the child table, and not the parent table. No doubt there is a good A5 reason for this, but that�s beyond my knowledge and ability.
I�ve tried the �lookup� system in the field rules, but that is not really satisfactory; nor is many other ideas I�ve tried. I�m sure this should not be too hard for you very clever A5 gurus out there, and would seem to be a reasonably simple requirement of A5, but A5 does not seem to want to easily allow it, and it�s beyond me at the moment. I would greatly appreciate any and all help on this.
Many thanks
adooke
Comment