[AccessD] A2003: Undo Changes to a subform

Ken Ismert KIsmert at TexasSystems.com
Tue Apr 5 12:39:51 CDT 2005


Darren:

Charlotte's right: you can't undo a subform from the parent using an Access
control. But... you can trick Access Forms by adding a Microsoft Common
Controls Toolbar to your form. When you click on an ActiveX control in a
form, it DOESN'T fire the usual Access events, so you can very likely get a
subform Undo to work, if you place the button in a Toolbar.

Although some members of this forum recommend against all ActiveX controls,
I've used this one for years with no real issues. It isn't as problemmatic
as some of the other ActiveX controls I've tangled with.

-Ken

PS. I have some really simple button icons for toolbars that dress it up
nicely, with out too much effort. Email me offline if you'd like a copy,
plus some basic instructions.


-----Original Message-----
From: Charlotte Foust [mailto:cfoust at infostatsystems.com]
Sent: Monday, April 04, 2005 7:45 PM
To: Access Developers discussion and problem solving
Subject: RE: [AccessD] A2003: Undo Changes to a subform


You can't do it simply, Darren.  When you click the button on the parent
form, the subform record is saved automatically, so undo is no longer
available.  The way I have done this in the past is either with an
unbound subform which can be cleared, by deleting the subform record, or
by storing the current value of each field to the field's tag property
and then overwriting the new value if the decided to "undo."

Charlotte Foust


-----Original Message-----
From: Darren DICK [mailto:d.dick at uws.edu.au]
Sent: Monday, April 04, 2005 4:32 PM
To: 'Access Developers discussion and problem solving'
Subject: [AccessD] A2003: Undo Changes to a subform


Hello all
This should be simple :-))

If I type me.undo and attach it to a button on a form I can undo edits
to a record.

If I have a main form that has a sub form in it and if I attach code
something like Forms!MyForm!MySubForm.Form.Undo to a button on the main
form with the intention of Undo-ing any edit to the sub form it doesn't
seem to work

How do I undo edits to a sub form from a button on the parent form??

Many thanks

Darren




--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com






More information about the AccessD mailing list