Another refresh / requery

Bagel

Registered User.
Local time
Today, 00:12
Joined
Jun 13, 2003
Messages
15
Hi all

I am sorry if this has been asked already a million times already but I could not find any relavant information in the time I had.

I have a requery / refresh problem.

I have a Customers form showing all customers, I also have a NewCustomer form for adding new customers.

On the Customer form, on activate I have me.refresh

On the NewCustomer form I have in the onclose,

If IsLoaded("Customers") Then
Forms!Customers.Requery

These work well however if Customers is open and I enter a new record in the New Customer Form, then view the Customer form again the new record is not shown.

I can however click back on the NewCustomer from then straight back to Customers and Hey Presto it appears

Any clues as to what I need to do to update the form?

Thank you in advance for your help
 
This is probably because your newly entered record is not saved yet.
What you needed to do is to

on customers form on activate
me.requery

on newcustomer form on deactivate
me.refresh
 
Thanks Alexei you are bang on, worked perfectly.

Thank you for your help

Regards

Bagel
 

Users who are viewing this thread

Back
Top Bottom