Hi, I have a form that shows data from 3 different queries using subforms. It takes the DB a few seconds to refresh each query if a user chooses a different filter criteria from the form. What I want to do is make the subforms invisible whilst they are refreshing then make them visible again when they have been refreshed.
I simply used:
Me![subform1].Visible = False
Me![subform2].Visible = False
Me![subform3].Visible = False
Me![subform1].Requery
Me![subform2].Requery
Me![subform3].Requery
Me![subform1].Visible = True
Me![subform2].Visible = True
Me![subform3].Visible = True
but that doesn't work, it seems to perform the requerys first (leaving the subforms visible) even though they're not the initial lines of code. If I take out the .Visible = True parts then it refreshes then makes the subforms invisible???
I tried putting the requery parts in a different sub then calling that sub inbetween the invisible/visible parts but that didn't make a difference. Can anyone tell me why it's doing that? Thanks, Tom.
I simply used:
Me![subform1].Visible = False
Me![subform2].Visible = False
Me![subform3].Visible = False
Me![subform1].Requery
Me![subform2].Requery
Me![subform3].Requery
Me![subform1].Visible = True
Me![subform2].Visible = True
Me![subform3].Visible = True
but that doesn't work, it seems to perform the requerys first (leaving the subforms visible) even though they're not the initial lines of code. If I take out the .Visible = True parts then it refreshes then makes the subforms invisible???
I tried putting the requery parts in a different sub then calling that sub inbetween the invisible/visible parts but that didn't make a difference. Can anyone tell me why it's doing that? Thanks, Tom.