logo
search
VBA & Macro Problems

Fix Excel Active Row Highlighting Not Working After Reopening

Rana GarciaRana Garcia Sep 25, 2026 868 views

Question details

The user's active row highlighting setup stops functioning correctly after the workbook is reopened or uploaded to a SharePoint environment.

Fix Excel Active Row Highlighting Not Working After Reopening
Product
Microsoft Excel
Device & OS
not provided
Scenario
Reopening a macro-enabled workbook locally or editing it collaboratively via SharePoint and Excel for the web.
Observed behavior
The complete active row is no longer highlighted upon cell selection, despite the =ROW()=CELL("row") conditional formatting rule and VBA script being previously configured.
Before you start

Ensure that your file is saved as a Macro-Enabled Workbook (.xlsm) and that macros are fully enabled in your Excel Trust Center settings.

Solution 1Recommended

Use Desktop Excel and Verify the VBA Trigger

Excel for the web and SharePoint do not support VBA execution. Opening the file in the desktop app and ensuring the selection event forces a recalculation will restore the highlighting.

Conditional formatting rules that rely on the CELL function require a worksheet recalculation to update visually when a new cell is selected. This recalculation is handled by a VBA macro, which cannot run in web-based Excel environments like SharePoint.

1
Open in Desktop App

If you are viewing the workbook in SharePoint or a web browser, click on the 'Viewing' or 'Editing' button on the top ribbon, and select 'Open in Desktop App'.

2
Access the VBA Editor

In the desktop version of Excel, press the Alt + F11 keys simultaneously to open the Visual Basic for Applications (VBA) editor.

3
Verify Recalculation Code

In the Project Explorer pane on the left, double-click the worksheet you are working on. Ensure the code window contains: Private Sub Worksheet_SelectionChange(ByVal Target As Range) followed by Target.Calculate and End Sub on the next lines.

Use Desktop Excel and Verify the VBA Trigger
Macro Security Warning: When reopening the file, you may see a yellow security warning bar at the top of the spreadsheet. You must click 'Enable Content' for the VBA highlighting script to run.
Free Microsoft Office alternative

Use WPS Office for Reliable Spreadsheet Management

If you frequently encounter macro limitations, web-editing constraints, or compatibility issues in SharePoint and Excel, consider switching to WPS Office. It provides a lightweight, highly compatible desktop environment designed to handle your spreadsheets efficiently without browser-based VBA restrictions.

  1. 1. Download WPS Office: Visit the official WPS website and click the download button to get the free, lightweight installer.
  2. 2. Install the Software: Run the setup file and follow the quick on-screen instructions to install the suite on your computer.
  3. 3. Open Your Spreadsheets: Launch WPS Spreadsheets, open your Excel workbooks, and experience fast, reliable editing with native desktop performance.
Completely free and lightweight Office suiteHigh compatibility with Microsoft Excel formats (.xlsx, .xls, .xlsm)Familiar ribbon interface requiring zero learning curveRobust desktop application avoiding web-based macro limitations
microsoft office alternative - wps office

Frequently Asked Questions

Why does conditional formatting with CELL("row") require VBA?

The CELL function is volatile, meaning it updates when the worksheet calculates, but simply clicking a new cell does not trigger a recalculation. A VBA Worksheet_SelectionChange event containing Target.Calculate is necessary to force Excel to recalculate and instantly update the row highlighting.

Does SharePoint or Excel for the web support VBA macros?

No, Excel for the web and the built-in SharePoint browser editor do not support the execution of VBA macros. To use features dependent on VBA, such as active row highlighting, you must open the workbook in your local desktop application.

Can I highlight both the active row and column simultaneously?

Yes. You can modify your conditional formatting formula to =OR(ROW()=CELL("row"), COLUMN()=CELL("col")) to highlight a crosshair (both row and column) of the currently selected cell, provided your VBA recalculation script is active.