Requery Field

  • Thread starter Thread starter Tom
  • Start date Start date
T

Tom

I need to help with requering a field.

A "master field" is part of a subform and resides on a tab-controlled sheet.
On another tab, I want to reference to the same master field when entering
its children records.

In other words, if the master field contains value "123" on Tab-A then I
want to also show "123" on Tab-B. So far, this works fine via using the
method below.

Me.Parent![NameOfChildSubform].Requery


Again, when changing the value from "123" to "456" on Tab-A, I also show
"456" on Tab-B. However, updating and immediately referencing the changed
value only works on existing records.

Here's what doesn't work...

If I enter a new record and select "789" on Tab-A, then "789" will NOT show
up on Tab-B. Actually, the "referenced master field" on Tab-B is empty
after having entered the new record.

I only show the value once the form has been closed and re-opened.

Does anyone know how to immediately show the value on Tab-B once the record
has been entered on Tab-A. I hope I provided enough information to make
sense out of this problem.


Thanks in advance,
Tom
 
Set the afterupdate event property of the control in tabA to requery th
form, not the field. Me.formname.requery. See if that works
 
I think ( repeat I think) you are a caught in that "You have to complete a record before you can take action on it." Do a refresh routine as you open Tab-B, this should make the data available

Hope this helps. Tidepuddle (aka Leon

----- Tom wrote: ----

I need to help with requering a field

A "master field" is part of a subform and resides on a tab-controlled sheet
On another tab, I want to reference to the same master field when enterin
its children records

In other words, if the master field contains value "123" on Tab-A then
want to also show "123" on Tab-B. So far, this works fine via using th
method below

Me.Parent![NameOfChildSubform].Requer


Again, when changing the value from "123" to "456" on Tab-A, I also sho
"456" on Tab-B. However, updating and immediately referencing the change
value only works on existing records

Here's what doesn't work..

If I enter a new record and select "789" on Tab-A, then "789" will NOT sho
up on Tab-B. Actually, the "referenced master field" on Tab-B is empt
after having entered the new record

I only show the value once the form has been closed and re-opened

Does anyone know how to immediately show the value on Tab-B once the recor
has been entered on Tab-A. I hope I provided enough information to mak
sense out of this problem


Thanks in advance
To
 
Hi,

thanks for the feedback... this kinda works... there's no "OpenEvent" for
the tabs. But w/ you hint I used the refresh routine OnChange for the
field on tab-B.

Unfortunately, I still don't see the refreshed value on tab-B when having
entered a new record on tab-A. However, once I enter the 2nd record on
tab-B, the reference field on tab-B is then updated.

'still not too happy w/ this... but's it's better than before. Again,
thanks for the info.

--
Thanks,
Tom


Tidepuddle said:
I think ( repeat I think) you are a caught in that "You have to complete a
record before you can take action on it." Do a refresh routine as you open
Tab-B, this should make the data available.
Hope this helps. Tidepuddle (aka Leon)

----- Tom wrote: -----

I need to help with requering a field.

A "master field" is part of a subform and resides on a tab-controlled sheet.
On another tab, I want to reference to the same master field when entering
its children records.

In other words, if the master field contains value "123" on Tab-A then I
want to also show "123" on Tab-B. So far, this works fine via using the
method below.

Me.Parent![NameOfChildSubform].Requery


Again, when changing the value from "123" to "456" on Tab-A, I also show
"456" on Tab-B. However, updating and immediately referencing the changed
value only works on existing records.

Here's what doesn't work...

If I enter a new record and select "789" on Tab-A, then "789" will NOT show
up on Tab-B. Actually, the "referenced master field" on Tab-B is empty
after having entered the new record.

I only show the value once the form has been closed and re-opened.

Does anyone know how to immediately show the value on Tab-B once the record
has been entered on Tab-A. I hope I provided enough information to make
sense out of this problem.


Thanks in advance,
Tom
 
Back
Top