Where to use Me.Dirty?

L

Lisa

Hello -
I would like to be able to edit a record and then go directly to a report
with a command button, having the record update without having to move off it
to another record first.

A macro runs behind the command button (not a programmer here), with a WHERE
argument to filter just the current record. But it doesn't update the record
on its way over to the report.

I know "if ME.Dirty then ME.Dirty=False" can be plugged in somewhere, but I
don't know where. I suspect I can't just plug that line in by itself
somewhere? I've tried just about every place I can think of.

Thanks in advance.
 
J

John W. Vinson

Hello -
I would like to be able to edit a record and then go directly to a report
with a command button, having the record update without having to move off it
to another record first.

A macro runs behind the command button (not a programmer here), with a WHERE
argument to filter just the current record. But it doesn't update the record
on its way over to the report.

I know "if ME.Dirty then ME.Dirty=False" can be plugged in somewhere, but I
don't know where. I suspect I can't just plug that line in by itself
somewhere? I've tried just about every place I can think of.

Thanks in advance.

If you're using a Macro (rather than VBA code), you can put a line in the
macro before it opens the report using the RunCommand action, with the
SaveRecord command - this does the same thing as Me.Dirty = False.
 
L

Lisa

Thank you John! Works great!

Lisa

John W. Vinson said:
If you're using a Macro (rather than VBA code), you can put a line in the
macro before it opens the report using the RunCommand action, with the
SaveRecord command - this does the same thing as Me.Dirty = False.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top