Microsoft Access - Keeping focus on Excel when calling from Access

Asked By Ben on 28-Aug-13 08:05 AM
I have set up some code on an Access Form which open's an Excel document and then run's a macro contained within the workbook. This works fine apart from if the user already has Excel open then the focus shifts back to the Access Form at the end of the code. If the user doesn't have Excel already open then the focus is correctly left on the workbook.

I'm happy to post some code if necessary but I thought i'd ask first if this is a common problem with a standard solution?
Robbe Morris replied to Ben on 28-Aug-13 08:07 AM
At the end of the Macro, you could set focus on a particular cell (A1).  You could also try setting the application object's .Visible and/or .UserControl equal to false and then set it to true (toggle it).