By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,483 Members | 1,574 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,483 IT Pros & Developers. It's quick & easy.

Refresh a Form

P: n/a
Dear reader,

I have a strange situation.

In a Form with a list box to search for a record in the form it self. The
field in the list box is also available in the form. On an other form I
have the same field after changing the field and closing the form with the
following code by the event on close:

Forms!FormNaneWithListBox.Refresh

Forms!FormNameWithListBox.Recalc

Only the field in the list box has the changed value and the value of the
field in the form it self remains the old one. Only after closing and
opening of the form with the list box al information on the form is changed.

In case close and open the Form is the only way to refresh the information
than a need a command to comeback on the same record as by closing the form.

Is there a command the refresh all information on the form.

Tanks fore any help.

Kind regards

Simon van Beek
Nov 13 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Not sure I follow you, but try using Requery instead of Refresh ... Refresh
simply requeries the underlying recorset, as it was created, including and
edits made by other users. Requery will rebuild the recordset and include
edited/new/deleted records. If you're trying to filter a form based on a
value in another form's listbox, then let us know the code you're using to
filter.


"S. van Beek" <S.******@HCCnet.nl> wrote in message
news:42*********************@reader1.nntp.hccnet.n l...
Dear reader,

I have a strange situation.

In a Form with a list box to search for a record in the form it self. The
field in the list box is also available in the form. On an other form I
have the same field after changing the field and closing the form with the
following code by the event on close:

Forms!FormNaneWithListBox.Refresh

Forms!FormNameWithListBox.Recalc

Only the field in the list box has the changed value and the value of the
field in the form it self remains the old one. Only after closing and
opening of the form with the list box al information on the form is
changed.

In case close and open the Form is the only way to refresh the information
than a need a command to comeback on the same record as by closing the
form.

Is there a command the refresh all information on the form.

Tanks fore any help.

Kind regards

Simon van Beek

Nov 13 '05 #2

P: n/a
Forms!MyForm.Requery will refresh form data, but unbound controls will
not be reset, because they are not bound--i.e. not coming from the
underlying table or query.

Forms!MyForm.MyListBox.Value = Null

will clear a list box, and indeed Null will reset any control that
doesn't have a calculated (i.e. beginning with "=") control source.

But it's not clear to me whether you want to refresh data, or jump to a
record, or synchronize two forms, so that's all I can offer.

Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.