A
Ascerbus
I have a form with two subforms on it. The first subform is continuous
and shows relevant data with an ORDER BY dtmDate DESC clause to show
most recent entries first. Items cannot be added to this subform but
may be edited since I don't think that I can have a new record entered
as the first line of this continuous form.
I created a workaround to this problem by creating a second subform,
sized so that it appears to be a part of the first subform with only
one record line showing. This subform is set to Data Entry = Yes. All
of this works well enough, however when I enter a new record line on
the data entry subform, it appears to the user that the data has
disappeared. It actually hasn't -- it is just appears this way since
the subform is sized to only show one record line at a time.
What I would like these two subforms to do is have the bottom subform,
with descending by date data listed continuously, update automatically
when I leave the last field of the record in the top data entry
subform. The way I have it set up now is that there is a command
button which refreshes the entire form so that the new entry appears on
the bottom subform -- it works but it is sloppy. The refresh code that
is under this button (generated by the wizard) does not work when
placed on the OnExit Event for the last control in the record of the
top subform.
Am I placing the code in the wrong event? Is there another bit of code
that I should use instead of the generated Refresh code? Is there a way
to actually use one subform and force a new record to show at the top
of the series of a continuous form? I am pretty new to Access so please
be gentle and describe any solutions to me in terms that a Martian
would understand. Thank you.
---Tim Dunne
and shows relevant data with an ORDER BY dtmDate DESC clause to show
most recent entries first. Items cannot be added to this subform but
may be edited since I don't think that I can have a new record entered
as the first line of this continuous form.
I created a workaround to this problem by creating a second subform,
sized so that it appears to be a part of the first subform with only
one record line showing. This subform is set to Data Entry = Yes. All
of this works well enough, however when I enter a new record line on
the data entry subform, it appears to the user that the data has
disappeared. It actually hasn't -- it is just appears this way since
the subform is sized to only show one record line at a time.
What I would like these two subforms to do is have the bottom subform,
with descending by date data listed continuously, update automatically
when I leave the last field of the record in the top data entry
subform. The way I have it set up now is that there is a command
button which refreshes the entire form so that the new entry appears on
the bottom subform -- it works but it is sloppy. The refresh code that
is under this button (generated by the wizard) does not work when
placed on the OnExit Event for the last control in the record of the
top subform.
Am I placing the code in the wrong event? Is there another bit of code
that I should use instead of the generated Refresh code? Is there a way
to actually use one subform and force a new record to show at the top
of the series of a continuous form? I am pretty new to Access so please
be gentle and describe any solutions to me in terms that a Martian
would understand. Thank you.
---Tim Dunne