網頁和 Excel 2003 XML 試算表 的登錄值 htmlandxmlssfiles使用者HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock
- 原則 ID
- L_WebPagesAndExcel2003XMLSpreadsheets
- 適用範圍
- 使用者設定
- 支援的作業系統
- 至少需要 Windows Server 2008 R2 或 Windows 7
- 來源
- Microsoft 365 Apps / Office Administrative Templates (版本 5568.1000)
- 類別
- Microsoft Excel 2016 › Excel 選項 › 安全性 › 信任中心 › 檔案封鎖設定
登錄
htmlandxmlssfiles
REG_DWORD使用者- 啟用時的值
- 取決於選項值
- 元素
- 檔案封鎖設定:
| 項目 | 儲存的值 |
|---|---|
| 不要封鎖 | 0 |
| 封鎖儲存 | 1 |
| 封鎖開啟/儲存,使用開啟原則 | 2 |
| 區塊 | 3 |
| 在受保護的檢視中開啟 | 4 |
| 允許在受保護的檢視中編輯和開啟 | 5 |
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\excel\security\fileblock] ; 選項 (只使用其中一個) ; 不要封鎖 "htmlandxmlssfiles"=dword:00000000 ; 封鎖儲存 "htmlandxmlssfiles"=dword:00000001 ; 封鎖開啟/儲存,使用開啟原則 "htmlandxmlssfiles"=dword:00000002 ; 區塊 "htmlandxmlssfiles"=dword:00000003 ; 在受保護的檢視中開啟 "htmlandxmlssfiles"=dword:00000004 ; 允許在受保護的檢視中編輯和開啟 "htmlandxmlssfiles"=dword:00000005
CMD
:: 選項 (只使用其中一個) :: 不要封鎖 reg add "HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock" /v "htmlandxmlssfiles" /t REG_DWORD /d 0 /f :: 封鎖儲存 reg add "HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock" /v "htmlandxmlssfiles" /t REG_DWORD /d 1 /f :: 封鎖開啟/儲存,使用開啟原則 reg add "HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock" /v "htmlandxmlssfiles" /t REG_DWORD /d 2 /f :: 區塊 reg add "HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock" /v "htmlandxmlssfiles" /t REG_DWORD /d 3 /f :: 在受保護的檢視中開啟 reg add "HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock" /v "htmlandxmlssfiles" /t REG_DWORD /d 4 /f :: 允許在受保護的檢視中編輯和開啟 reg add "HKCU\software\policies\microsoft\office\16.0\excel\security\fileblock" /v "htmlandxmlssfiles" /t REG_DWORD /d 5 /f
PowerShell
# 共通: 建立機碼 New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Force | Out-Null # 選項 (只使用其中一個) # 不要封鎖 New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Name 'htmlandxmlssfiles' -PropertyType DWord -Value 0 -Force | Out-Null # 封鎖儲存 New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Name 'htmlandxmlssfiles' -PropertyType DWord -Value 1 -Force | Out-Null # 封鎖開啟/儲存,使用開啟原則 New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Name 'htmlandxmlssfiles' -PropertyType DWord -Value 2 -Force | Out-Null # 區塊 New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Name 'htmlandxmlssfiles' -PropertyType DWord -Value 3 -Force | Out-Null # 在受保護的檢視中開啟 New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Name 'htmlandxmlssfiles' -PropertyType DWord -Value 4 -Force | Out-Null # 允許在受保護的檢視中編輯和開啟 New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\excel\security\fileblock' -Name 'htmlandxmlssfiles' -PropertyType DWord -Value 5 -Force | Out-Null