Changing form recordsource with code in Access 2007

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

In an Access 2000 DB I use the following code to change the recordsource for
a subform depending in certain conditions. It has worked for years in A2000
but when I open the DB with Access 2007 the default recordsource is not
overridden. the rest of the DB seems to be working as it did in A2000

Me.Record_Scores_subform.Form.RecordSource = "Indvls for Scores"

Is this a known issue and/or is there a fix?

Any and all help is appreciated.
 
Steve,

Try setting the forms recordsource to an empty string first. Maybe it's a
requery thing.

So:

Me.Record_Scores_subform.Form.RecordSource = ""
Me.Record_Scores_subform.Form.RecordSource = "Indvls for Scores"

hth
 
sorry to take so long to reply but I had other issues ti deal with. I tried
your suggestion - no luck. The query 'Indvls for Scores' returns the
expected results when ran by itself.

Any other suggestions??
 
Back
Top