What is wrong with this code ??
DoCmd.OpenQuery "Siblings_Query", acViewNormal, acReadOnly
Me.Refresh 'Refresh the query
DoCmd.OpenForm "frm_Pupils"
Me.Refresh
The query works fine when I open it manually and refresh it manually. Its pulling criteria from a control on a form WHICH IS OPEN.
When I try to run it from the code above, it doesnt refresh.
Thanks
Al
DoCmd.OpenQuery "Siblings_Query", acViewNormal, acReadOnly
Me.Refresh 'Refresh the query
DoCmd.OpenForm "frm_Pupils"
Me.Refresh
The query works fine when I open it manually and refresh it manually. Its pulling criteria from a control on a form WHICH IS OPEN.
When I try to run it from the code above, it doesnt refresh.
Thanks
Al