Re: Options Group, AfterUpdate Event, OldValue Property and ControlSou

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



"Ted" <Ted@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:11770BD7-1530-4F73-98C4-1047D78C1AC9@xxxxxxxxxxxxx
i'm using a2k and i've posted variations of this theme in recent days
but just seem to be getting stuck deeper in things as the plot
thickens.....

in broad sweeping terms ( :-) ), when my user is looking at his
choices from amongst the 7 radion buttons in the Frame1 options
group, there is an interest in launching certain macros (which have
either append, delete or update queries attached to them) depending
upon a) the radio button selected and b) the value of the radio
button before it was modified by the user. i'm new to this aspect of
a2k, so my impression is that while the user is sitting on a record,
every time he/she selects one of the radio buttons in the Frame1
options group the following happens 1) the value of the options
group's control source i dubbed 'Outcome_' changes and 2, the
OldValue property is updated to reflect the previous value of the
radio button's. i don't think that this is really how vba is set up
so if you can help straighthen me out, i'd appreciate it.

You're right, that's not how the OldValue property works. The OldValue
property holds whatever value the field held when the record was
initially loaded into the form, up until the moment the record is saved.
That means that if your Frame1 is bound to a field, and that field has a
value of 1, for example, when the form moves to a particular record,
then Frame1.OldValue will be 1 when the record is loaded *and will
remain 1 until the record is saved*, no matter how many times you change
the value of Frame1 before you save the record.

Further, if Frame1 is not bound to a field, its OldValue property is
always the same as its Value property, as there's no underlying record
to pull the OldValue property from.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)


.


Quantcast