>>>OK, lets see if I can explain what I need here :-).
>>>
>>>1. I have a page frame set up where the first page is to enter in customer data the second page is a grid where they can see the items already entered in for that customer on page one.
>>>
>>>2. The client needs to add a new item for the current customer on page 2. This is no problem I have it doing this. The problem is that the customer id from page 1 is not being saved in the items table from page 2.
>>>
>>>3.So when you save the record it is no longer there because the customer id did not get saved with the rest of the data in the items table.
>>>
>>>How do I get the customer id from page 1 to be saved with the items data on page 2?
>>>
>>>Thanks for any assistance.
>>
>>
>>How are you adding the new item record? APPEND BLANK? Use INSERT-SQL to place the customer number in the new record before adding the item.
>
>
>I'm using the add button from the wizard. Which I assumes appends a blank.
IMHO, once you've gained a comfortable familiarity with VFP, stop using the wizards, their generic nature usually means a lot of unnecessary coding..
In the meantime..
place code
like this in the add button
...
wizbuttonclass::cmdAdd
IF THIS.Parent.EditMode .AND. EMPTY(cust_id) && assumes item table is current
REPLACE cust_id WITH
id_from_page_1ENDIF
...
HTH
Matt McDonnell
...building a better mousetrap with moldy cheese...