| General Fault wrote:|
So, if I wanted to change the RecordSource property in the grid inside Form1 from Form2 what should I do
Add a property called oCaller to form 2 and initialize it to .NULL. in the property sheet. You do this from the form menu ->New Property. This code goes in Form 2's Init():
Thisform.oCaller = toCaller
Then the calling form is available from any method in form 2.
You manipulate the grid in form 1 by referring to Thisform.oCaller.<< Whatever the name of the grid in Form 1 is >>
If you are messing around with the grid's RecordSource, I suggest you read Andy's blog entry at http://weblogs.foxite.com/andykramek/archive/2005/03/19/174.aspx first to save yourself some aggravation.