ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   AppActivate syntax - help needed (https://www.excelbanter.com/excel-programming/424744-appactivate-syntax-help-needed.html)

Tom Joseph

AppActivate syntax - help needed
 
I am trying to use AppActivate to reset the focus to Excel.

When the workbook is not maximized and the title bar says Microsoft Excel
AppActivate ("Microsoft Excel") works fine.

If the workbook is maximized the above does not work.

The file name is Dashboard_v2441.xlsm and the title bar reads:
Dashboard_v2441.xlsm - Microsoft Excel
(when maximized).

Can someone please provide the exact syntax I would need to get this to work
reliably when maximized, with paren/quotes if needed?

Also, if there are any other considerations/tricks to get the focus reset
reliably, I would appreacte a note.

Thanks,


Tim Williams[_2_]

AppActivate syntax - help needed
 
Have you tried

AppActivate Application.Caption

?

Assuming this code is running in Excel.

Tim


"Tom Joseph" wrote in message
...
I am trying to use AppActivate to reset the focus to Excel.

When the workbook is not maximized and the title bar says Microsoft Excel
AppActivate ("Microsoft Excel") works fine.

If the workbook is maximized the above does not work.

The file name is Dashboard_v2441.xlsm and the title bar reads:
Dashboard_v2441.xlsm - Microsoft Excel
(when maximized).

Can someone please provide the exact syntax I would need to get this to
work
reliably when maximized, with paren/quotes if needed?

Also, if there are any other considerations/tricks to get the focus reset
reliably, I would appreacte a note.

Thanks,





All times are GMT +1. The time now is 11:10 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com