How to highlight taskbar at the bottom of the screen

pxcpyc

New Member
Joined
Dec 23, 2009
Messages
3
I have an Excel vba program that creates /opens another Excel file that stores the data generated by my program. The 2 workbooks are open at the same time. When the program has completed its action, a worksheet in the data file is displayed, but the button that is highlighted in the taskbar at the bottom of the screen is the program button.

To return to a worksheet in the program workbook, I have to click on another program button in the task bar then the button for the program. In practice, I usually finish up clicking multiple buttons/programs before I get where I want.

I have tried to overcome this with the following code at the end of my modules:

Application.Workbooks(ProgramName).Activate
Application.ScreenUpdating = True
Application.Workbooks(XLFileName).Activate

The problem with this approach is that I get screen jump each time, and it is very annoying after a few hundred times.

Can anyone suggest a better fix?

thanks

(XP and Excel 2007)
 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
I have added Status bar progress messages to my program and that has fixed the problem eg:

'Status bar progress message
Application.StatusBar = "Save Program ..."
....
vba code
....
'Return control of the status bar to the program
Application.StatusBar = False

'''''To highlight the correct Taskbar button at the bottom of the screen, I have had to add the following 2 Activate lines, 1
'''''either side of the Screen update.
''''Application.Workbooks(XLFileName).Activate

'Screen updating reset
Application.ScreenUpdating = True

''''Application.Workbooks(ProgramName).Activate
 
Upvote 0

Forum statistics

Threads
1,223,760
Messages
6,174,341
Members
452,555
Latest member
colc007

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top