Sheet focus changes when you click a button to run a macro to protect or unprotect some Excel 2013 worksheets

Applies to: Excel 2013

Symptoms


When you click a button to run a macro to protect or unprotect some worksheets in a workbook in Microsoft Excel 2013, the sheet focus changes instead of staying on the sheet that contains the button.

Resolution


To resolve this issue, apply the following update:
2850006 Description of the Excel 2013 hotfix package (Excel-x-none.msp): December 10, 2013


Registry key information

Important
Follow the steps in this section carefully. Serious problems might occur if you modify the registry incorrectly. Before you modify it, back up the registry for restoration in case problems occur.


After you install this hotfix package, you can follow these steps to enable this hotfix:
  1. Click Start, click Run, type regedit in the Open box, and then click OK.
  2. Locate and then select the following registry subkey:
    HKEY_CURRENT_USER\Software\Microsoft\Office\15.0\Excel\Options\
  3. On the Edit menu, point to New, and then click DWORD Value.
  4. Type ExcelResetSheetAfterProtection, and then press Enter.
  5. In the Details pane, right-click ExcelResetSheetAfterProtection, and then click Modify.
  6. In the Value data box, type 1, and then click OK.
  7. Exit Registry Editor.

Status


Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.