A binary registry key is a byte array – each element of array will have values 0 to 255 in Powershell.
Should be easy enough to manipulate – get the [int] value of the byte you wish to manipulate, use –bxor (with appropriate value 1, 2, 4, 8, 16, 32, 64, or 128 depending on bit position) to flip the bit, write it all back. Cheers, Phil From: [email protected] [mailto:[email protected]] On Behalf Of James Rankin Sent: 22 August 2014 10:54 To: [email protected] Subject: [NTSysADM] PowerShell Any idea if you can toggle a particular bit of a byte in a binary Registry key using PowerShell? My head is busted trying to work this out.... -- James Rankin --------------------- RCL - Senior Technical Consultant (ACA, CCA, MCTS) | The Virtualization Practice Analyst - Desktop Virtualization http://appsensebigot.blogspot.co.uk Hoople Ltd, Registered in England and Wales No. 7556595 Registered office: Plough Lane, Hereford, HR4 0LE "Any opinion expressed in this e-mail or any attached files are those of the individual and not necessarily those of Hoople Ltd. You should be aware that Hoople Ltd. monitors its email service. This e-mail and any attached files are confidential and intended solely for the use of the addressee. This communication may contain material protected by law from being passed on. If you are not the intended recipient and have received this e-mail in error, you are advised that any use, dissemination, forwarding, printing or copying of this e-mail is strictly prohibited. If you have received this e-mail in error please contact the sender immediately and destroy all copies of it."

