SQLSecurityCheck
controls whether opening a Word document with a MailMerge causes a message box with the warning Office Object Model: Word - MailMerge. SQLSecurityCheck
is set to 0, the warning will not be issued. DeveloperTools
is set to 1, Word displays the developer tools (which is required(?) to record macros). HKEY_CURRENT_USER\Software\Microsoft\Office\_version_\Excel\Options
. $officeVersion = (get-item hklm:\Software\Classes\excel.application\curVer).getValue('') -replace '.*\.(\d+)', '$1.0' new-itemProperty ` -path "HKCU:\Software\Microsoft\Office\$officeVersion\Word\Options" ` -name SQLSecurityCheck ` -value 0 ` -propertyType dWord ` -force | ` out-null new-itemProperty ` -path "HKCU:\Software\Microsoft\Office\$officeVersion\Word\Options" ` -name DeveloperTools ` -value 1 ` -propertyType dWord ` -force | ` out-null