[AccessD] Lose Focus

John B. john at winhaven.net
Tue Sep 16 12:39:31 CDT 2003


I tried DoCmd.RunCommand acCmdSaveRecord but it doesn't work from the
function. I would have to include it in each indivdual  form module under an
event, which is what I'm trying to avoid doing.

I'm thinking of using one of Arthur's patented global functions to load the
form name in whenever a form is active and then referencing it in the
function.

Any other ideas?

> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com
> [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Charlotte
> Foust
> Sent: Tuesday, September 16, 2003 12:07 PM
> To: Access Developers discussion and problem solving
> Subject: RE: [AccessD] Lose Focus
>
>
> Here's a custom commandbar routine I've used.
>
> Public Function cbUndo()
>   On Error Resume Next
>   DoCmd.RunCommand acCmdUndo
> End Function 'cbUndo()
>
> Charlotte Foust
>
>
> -----Original Message-----
> From: John B. [mailto:john at winhaven.net]
> Sent: Tuesday, September 16, 2003 9:00 AM
> To: Access Developers discussion and problem solving
> Subject: RE: [AccessD] Lose Focus
>
>
> I've been reading up on this and ADH recommends not using ActiveForm.
>
> Maybe I'm overthinking this and missing something obvious but I'm
> definitely missing something :o)
>
> Can someone tell me how to save the record of the calling form when I
> can't pass the Me object to the function because it's being called from
> a shortcut menu?
>
> > -----Original Message-----
> > From: accessd-bounces at databaseadvisors.com
> > [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of John B.
> > Sent: Monday, September 15, 2003 5:41 PM
> > To: Access Developers discussion and problem solving
> > Subject: RE: [AccessD] Lose Focus
> >
> >
> > Charlotte:
> > That's what I'm experiencing. I have a function that is called by
> > shortcut menu from a number of different forms. The record needs to be
>
> > saved before it will work correctly. I could save the record
> > automatically in the after_update event but this would be saving the
> > record after each update for something that rarely occurrs.
> >
> > The only time this is an issue is if someone adds a new row (this is a
>
> > continuos form) and then uses the shortcut function immediately. Of
> > course a client just called and noted this. Click on another row first
>
> > is the immediate work around but not real obvious to them.
> >
> > I'm thinking I should be able to use ActiveForm to perform a
> > SaveRecord when the shortcut menu calls the function. Any help on that
>
> > idea would be welcome.
> >
> > John B.
> >
> > > -----Original Message-----
> > > From: accessd-bounces at databaseadvisors.com
> > > [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Charlotte
> > > Foust
> > > Sent: Monday, September 15, 2003 5:30 PM
> > > To: Access Developers discussion and problem solving
> > > Subject: RE: [AccessD] Lose Focus
> > >
> > >
> > > Sort of.  The exit event of the form doesn't occur, so context menu
> > > won't automatically trigger a save of the current record.
> > >
> > > Charlotte Foust
> > >
> > > -----Original Message-----
> > > From: Drew Wutka [mailto:DWUTKA at marlow.com]
> > > Sent: Monday, September 15, 2003 2:12 PM
> > > To: 'Access Developers discussion and problem solving'
> > > Subject: RE: [AccessD] Lose Focus
> > >
> > >
> > > It should because the popup menu would have the focus.
> > >
> > > Drew
> > >
> > > -----Original Message-----
> > > From: John B. [mailto:john at winhaven.net]
> > > Sent: Monday, September 15, 2003 4:57 PM
> > > To: AccessD
> > > Subject: [AccessD] Lose Focus
> > >
> > >
> > > Does the Lose Focus event fire when then shortcut menu is popped up?
> > >
> > > John B.
> > >
> > > _______________________________________________
> > > AccessD mailing list
> > > AccessD at databaseadvisors.com
> > > http://databaseadvisors.com/mailman/listinfo/accessd
> > > Website: http://www.databaseadvisors.com
> > > _______________________________________________
> > > AccessD mailing list
> > > AccessD at databaseadvisors.com
> > > http://databaseadvisors.com/mailman/listinfo/accessd
> > > Website: http://www.databaseadvisors.com
> > > _______________________________________________
> > > AccessD mailing list
> > > AccessD at databaseadvisors.com
> > > http://databaseadvisors.com/mailman/listinfo/accessd
> > > Website: http://www.databaseadvisors.com
> > >
> > >
> >
> >
> > _______________________________________________
> > AccessD mailing list
> > AccessD at databaseadvisors.com
> > http://databaseadvisors.com/mailman/listinfo/accessd
> > Website: http://www.databaseadvisors.com
> >
> >
>
>
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
> _______________________________________________
> 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