Refresh combo/form/subform with new record (1 Viewer)

AlanM

Registered User.
Local time
Today, 15:50
Joined
Jul 11, 2004
Messages
28
This is for a Seminars Database:

I have a form with an unbound combobox (SeminarsCombo) in the header section used to select a Seminar. The detail section of the form is hidden. The "afterupdate" event of the combo causes the detail section to become visible and display info for the selected Seminar. The detail section also includes a subform for displaying Seminar Sessions info (the subform has a cascading combo to select the sessions for the Seminar).

Because many Seminars are exactly the same as a previous one (same topics, venue, etc - only the date changes), I have a button in the Header section, to "clone" the current Seminar. The OnClick event for the button adds a record to the Seminars table, based on the current Seminar record visible on the form, but with a new Id (Autonumber), and a special Seminar name. All this works fine.

BUT now I want to the automatically refresh the SeminarsCombo in the form header, AND re-run the "combo selection" for the new cloned event (just as if the user had actually selected it in the combo), so the user can then edit the cloned Seminar information on the form/subform.

I have searched the forums and seen lots of references to refresh, requery, etc, but haven't been able to find a solution for this particular situation.

Any/all assistance much appreciated.

regards
AlanM
 

Fernando

Registered User.
Local time
Yesterday, 23:50
Joined
Feb 9, 2007
Messages
89
What i understand from what u r saying is that you want to display the new seminars you added in SeminarsCombo without having to close and reopen. You said u searched for requery, Have you tried this on SeminarsCombo got focus event??

SeminarsCombo.Requery
 

Users who are viewing this thread

Top Bottom