Before you do the report do the following:
thisform.grid1.recordsource = ""
do report
thisform.grid1.recordsource ='Oldrecordsource'
Setting the recordsource to "" will preserve the grid setting even though recordsource has gone out of focus.
Gaylen
>I'll try it. Here's another question on another topic.
>
>Suppose you have a form that contains a grid in a parent child relationship. Then you pull a report from a menu. The data environment for the report is the opposite of the form. Parent becomes child, child becomes parent. The switch and restore is handled in the procedure code in the menu. After the report is run and control returns to the form, the grid on the form has lost its setup. Rows and columns are gone and there is no data in the grid. I can restore it column by column in the program code but this is a pain. Do you know an easy way to capture the grid's property sheet and then restore it after the data environment is switched and then switched back?
>
>Thanks