Need Urgent Help!

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have code for Form-Current it works just fine
when I run the form for all records.
However, if I do a search for particular record or records.
It doesn't run the code in Form-Current.
How can I force it to run?
I have a demo in an hour from now. Any help will be
highly appreciated.

Thank you,
-Me
 
OnCurrent runs for me when I select a specific record.
I use a combo box to go to specific records in the recordset.
How are you searching for your records?
-Jim
 
Jim,

I am using Access form menu -> Record -> Filter by Form
then enter my search criteria in the field or fields I am
doing a search and executing it.

Thank you,
-Me
 
That just filters the form's recordset. It will not cause changes of the
record initially.

You might use the Filter event to call the Current event procedure?
 
I've never used Filter by Form and I'm not an Access MVP so others will need
to assist you.
However, barging ahead where others fear to tread 8-):

I suspect the FormCurrent event is not where you want to put your code in
this case.
Investigate the events that fire for you by adding event code in all the
events listed on the form's property sheet. Something like msgbox ("Open
event fired") or ("Load event fired"), etc. Then watch to see which events
fire, pick an appropriate event and fire your "current" code from there. Be
sure to read the help file description for each event to make sure you are
picking the appropriate event.

Hope this helps,
Jim
 
Ken,

Thanks a lot!
Why Form_Current works when I don't filter records?
It executes the form current? Can you please reply for
my understanding?

Appreciate your help! It has kinda saved my job.
-Me
 
When you navigate to a different record, the Current event occurs. Even
after you filter the records, if you move from the "first" found record to
the "second" found record, the Current event then will occur. But it won't
occur when you first filter the form.
 
Back
Top