Disable predefined commands: registry value filepublishaswebpage and 15 more (excel\disabledcmdbaritemscheckboxes)UserHKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes

Policy ID
L_Disablecommandbarbuttonsandmenuitems
Scope
User Configuration
Supported on
At least Windows Server 2008 R2 or Windows 7
Source
Microsoft 365 Apps / Office Administrative Templates (version 5568.1000)
Category
Microsoft Excel 2016 › Disable Items in User Interface › Predefined

Registry

filepublishaswebpage

Delete valueUser
Disabled value
(delete value)
Apply with .reg · CMD · PowerShell
Disabled
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]
"filepublishaswebpage"=-
CMD · Disabled
reg delete "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "filepublishaswebpage" /f
PowerShell · Disabled
Remove-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'filepublishaswebpage'

weboptions

Delete valueUser
Disabled value
(delete value)
Apply with .reg · CMD · PowerShell
Disabled
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]
"weboptions"=-
CMD · Disabled
reg delete "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "weboptions" /f
PowerShell · Disabled
Remove-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'weboptions'

generaloptions

Delete valueUser
Disabled value
(delete value)
Apply with .reg · CMD · PowerShell
Disabled
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]
"generaloptions"=-
CMD · Disabled
reg delete "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "generaloptions" /f
PowerShell · Disabled
Remove-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'generaloptions'

fileopensearchtheweb

Delete valueUser
Disabled value
(delete value)
Apply with .reg · CMD · PowerShell
Disabled
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]
"fileopensearchtheweb"=-
CMD · Disabled
reg delete "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "fileopensearchtheweb" /f
PowerShell · Disabled
Remove-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'fileopensearchtheweb'

filewebpagepreview

REG_SZUser
Checked
3655
Unchecked
0
Element
File tab | Options | Customize Ribbon | All Commands | Web Page Preview
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"filewebpagepreview"="3655"
; Unchecked
"filewebpagepreview"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "filewebpagepreview" /t REG_SZ /d 3655 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "filewebpagepreview" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'filewebpagepreview' -PropertyType String -Value '3655' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'filewebpagepreview' -PropertyType String -Value '0' -Force | Out-Null

sendtomailrecipient

REG_SZUser
Checked
2188
Unchecked
0
Element
File tab | Share | Email
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"sendtomailrecipient"="2188"
; Unchecked
"sendtomailrecipient"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "sendtomailrecipient" /t REG_SZ /d 2188 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "sendtomailrecipient" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'sendtomailrecipient' -PropertyType String -Value '2188' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'sendtomailrecipient' -PropertyType String -Value '0' -Force | Out-Null

inserthyperlink

REG_SZUser
Checked
1576
Unchecked
0
Element
Insert tab | Links | Hyperlink
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"inserthyperlink"="1576"
; Unchecked
"inserthyperlink"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "inserthyperlink" /t REG_SZ /d 1576 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "inserthyperlink" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'inserthyperlink' -PropertyType String -Value '1576' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'inserthyperlink' -PropertyType String -Value '0' -Force | Out-Null

toolsprotectsheet

REG_SZUser
Checked
893
Unchecked
0
Element
Review tab | Changes | Protect Sheet
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"toolsprotectsheet"="893"
; Unchecked
"toolsprotectsheet"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsprotectsheet" /t REG_SZ /d 893 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsprotectsheet" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsprotectsheet' -PropertyType String -Value '893' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsprotectsheet' -PropertyType String -Value '0' -Force | Out-Null

flyoutanchorprotectworkbookmenu

REG_SZUser
Checked
16132
Unchecked
0
Element
Review tab | Changes | Protect Workbook
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"flyoutanchorprotectworkbookmenu"="16132"
; Unchecked
"flyoutanchorprotectworkbookmenu"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "flyoutanchorprotectworkbookmenu" /t REG_SZ /d 16132 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "flyoutanchorprotectworkbookmenu" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'flyoutanchorprotectworkbookmenu' -PropertyType String -Value '16132' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'flyoutanchorprotectworkbookmenu' -PropertyType String -Value '0' -Force | Out-Null

toolsprotectshare

REG_SZUser
Checked
3059
Unchecked
0
Element
Review tab | Changes | Protect and Share Workbook
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"toolsprotectshare"="3059"
; Unchecked
"toolsprotectshare"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsprotectshare" /t REG_SZ /d 3059 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsprotectshare" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsprotectshare' -PropertyType String -Value '3059' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsprotectshare' -PropertyType String -Value '0' -Force | Out-Null

flyoutanchormacros

REG_SZUser
Checked
16106
Unchecked
0
Element
View tab | Macros | Macros
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"flyoutanchormacros"="16106"
; Unchecked
"flyoutanchormacros"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "flyoutanchormacros" /t REG_SZ /d 16106 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "flyoutanchormacros" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'flyoutanchormacros' -PropertyType String -Value '16106' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'flyoutanchormacros' -PropertyType String -Value '0' -Force | Out-Null

toolsmacromacros

REG_SZUser
Checked
186
Unchecked
0
Element
Developer tab | Code | Macros
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"toolsmacromacros"="186"
; Unchecked
"toolsmacromacros"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacromacros" /t REG_SZ /d 186 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacromacros" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacromacros' -PropertyType String -Value '186' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacromacros' -PropertyType String -Value '0' -Force | Out-Null

toolsmacrorecord

REG_SZUser
Checked
184
Unchecked
0
Element
Developer tab | Code | Record Macro
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"toolsmacrorecord"="184"
; Unchecked
"toolsmacrorecord"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacrorecord" /t REG_SZ /d 184 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacrorecord" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacrorecord' -PropertyType String -Value '184' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacrorecord' -PropertyType String -Value '0' -Force | Out-Null

toolsmacrosecurity

REG_SZUser
Checked
3627
Unchecked
0
Element
Developer tab | Code | Macro Security
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"toolsmacrosecurity"="3627"
; Unchecked
"toolsmacrosecurity"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacrosecurity" /t REG_SZ /d 3627 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacrosecurity" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacrosecurity' -PropertyType String -Value '3627' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacrosecurity' -PropertyType String -Value '0' -Force | Out-Null

toolsmacrovbe

REG_SZUser
Checked
1695
Unchecked
0
Element
Developer tab | Code | Visual Basic
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"toolsmacrovbe"="1695"
; Unchecked
"toolsmacrovbe"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacrovbe" /t REG_SZ /d 1695 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "toolsmacrovbe" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacrovbe' -PropertyType String -Value '1695' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'toolsmacrovbe' -PropertyType String -Value '0' -Force | Out-Null

webaddress

REG_SZUser
Checked
1740
Unchecked
0
Element
File tab | Options | Customize Ribbon | All Commands | Document Location
Value type
REG_SZ
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes]

; Options (use only one)
; Checked
"webaddress"="1740"
; Unchecked
"webaddress"="0"
CMD
:: Options (use only one)

:: Checked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "webaddress" /t REG_SZ /d 1740 /f
:: Unchecked
reg add "HKCU\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes" /v "webaddress" /t REG_SZ /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Force | Out-Null

# Options (use only one)
# Checked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'webaddress' -PropertyType String -Value '1740' -Force | Out-Null
# Unchecked
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\disabledcmdbaritemscheckboxes' -Name 'webaddress' -PropertyType String -Value '0' -Force | Out-Null