Copying Last Record

S

Steph

I have setup a button on the main form (Called FlyScreen) that users
can click and it automatically copies the last record that the user
has entered in the subform (Called FlyScreenSub) in datasheet view.

However on the FlyScreenSub form when they select a value from a combo
box called Type it automatically calculates a deduction on the Height
field.

The problem is when you copy the last record it copies the already
already Height value, then reapplies the deduction.

If someone could advise me how I can copy the last record without
running the calculation on the new record.

TIA
Stephen
 
M

Michel Walsh

HI,


Either use Me.NewRecord, which is true for a new record, so make the
"deduction" only when the record is NOT new ? either use a Boolean variable
as safeguard, in the same spirit. You are in a better position than us to
know about the exact mechanic you use for "deduction". If that makes no
sense, then change your algorithm? append NULL as default for a new
"height"?



Hoping it may help,
Vanderghast, Access MVP.
 

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