Create (Powershell) script to turn off certain Power management settings in Device Manager


Bramgg

New member
Local time
7:07 PM
Posts
1
OS
Windows 11
I have a Dell XPS 13 (9310) and I have experienced issues with the bluetooth connection. I use a Microsoft Surface Precision Mouse, which never had any problems with other devices.

With the XPS, whenever I leave the mouse for a coupole of seconds, and try to use it again, it 'hangs/freezes' for 1/1,5 seconds before I can use it again. It seems like a common problem on XPS devices.

So, I found this fix on YouTube. And it does seem to fix my problem!

However, every time the device gets an update, this setting (Turn off the checkmark for allowing the computer to turn off the device to save energy) gets overwritten and it is being enabled again.

I want to create a (Powershell) script to disable this specific setting, so I can run this after each update. Or I would be able to run this script every time the device is booted up. The problem is that I have zero experience in coding/scripting and was hoping for someone on this forum to be able (and willing) to help me out.

Many thanks in advance!
 
Windows Build/Version
21H2 (22000.856)

My Computer

System One

  • OS
    Windows 11
    Computer type
    Laptop
    Manufacturer/Model
    Dell XPS 13 9310
    CPU
    Intel i7 (11th Gen.)
I suggest you use NirSoft RegScanner to find out if a particular Registry entry is being changed when you manually turn off the checkmark for allowing the computer to turn off the device to save energy.
- You run the utility to allow it to make a list of the 'before' state of the Registry. It will seem like it's taking forever.
- You do your change manually.
- You run the utility again and it will identify Registry changes that have taken place. Some will be red herrings so post your results and other forum members should be able to guide you to identify the relevant entry.

When you identify & post the change to the Registry that happens then a script to set it the way you want can be provided [by many forum members].
The script can be put together in several forms such as - a .reg file, a batch file, a vbs file, a PowerShell file.
There might be a complication arising from whatever access permissions are set by Windows for the relevant Registry key but that can only be considered properly when the Registry change is known.

All the best,
Denis



Welcome to ElevenForum.

It's really worth making time to browse through the Tutorial index - there's a shortcut to it at the top of every page [within the Tutorials dropdown list].
- At the foot of the Tutorial index is a shortcut to download it as a spreadsheet.
- I download a new copy each month.
- By downloading it as a spreadsheet I can benefit from Excel's excellent filtering capabilities when I search for topics of interest.
- Tutorials are also listed at Tutorials - there's a shortcut to that at the top of every page.

You can search ElevenForum using the search box in the top-right corner of all ElevenForum webpages or using Advanced Search - ElevenForum
- You can also search ElevenForum threads in many general search engines, such as Google, by adding site:elevenforum.com after your search term. For example,
Taskbar setup site:elevenforum.com
- [This is what the search box in the top-right corner of ElevenForum webpages does automatically]
 
Last edited:

My Computer

System One

  • OS
    Windows 11 Home x64 Version 23H2 Build 22631.3447
Hey @Try3 any chance you have a link to a Windows 10 version of that Tutorial list? That's a really handy spreadsheet to keep on hand.
 

My Computer

System One

  • OS
    Windows 10 & 11
@Jamus - is this what you are after

 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 Build-22631.3880
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home built
    CPU
    Intel S1200 Core i3 10105
    Motherboard
    Gigabyte S1200 MicroATX B560M DS3H DDR4
    Memory
    32.0 GB
    Graphics Card(s)
    MSI GT710 2GB PCIe Video Card
    Sound Card
    Realtek® Audio CODEC
    Monitor(s) Displays
    Dual Acer 24in
    Screen Resolution
    1920 x 1080
    Hard Drives
    500GB Crucial P1 M.2 PCIe SSD
    PSU
    500W
    Case
    Thermaltake ATX Versa H21 Case
    Cooling
    Internal fans by (3)
    Keyboard
    Microsoft Wireless Keyboard 850
    Mouse
    Microsoft Wireless mouse
    Internet Speed
    50Mbps / 20Mbps
    Browser
    Chrome
    Antivirus
    Defender, Malwarebyte
  • Operating System
    Windows 11 Pro 23H2 Build-22631.3880
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home built Test-PC
    CPU
    Intel(R) Core(TM) i5-4460 CPU @ 3.20GHz
    Motherboard
    ASUS S1150 MicroATX B85M-E
    Memory
    12.0 GB
    Graphics card(s)
    Integrated Video Card
    Sound Card
    Integrated Sound Card
    Monitor(s) Displays
    Chimei 22"
    Screen Resolution
    1680 x 1050
    Hard Drives
    120GB WD 2.5" Green SATA 6Gb/s SSD
    1TB WD 3.5" 7200rpm SATA 6Gb/s Caviar Blue
    PSU
    400W
    Case
    Cougar MicroATX MG100 Case Black
    Cooling
    Deepcool 120mm Case Fan
    Mouse
    Logitech Wireless mouse
    Keyboard
    Logitech Wireless keyboard
    Internet Speed
    50Mbps / 20Mbps
    Browser
    Chrome
    Antivirus
    Defender
    Other Info
    Only running Win 11 on this PC for test purposes
Hey @Try3 any chance you have a link to a Windows 10 version of that Tutorial list? That's a really handy spreadsheet to keep on hand.

See my post #3 in System BIOS - Windows 10 Help Forums
[It is not possible to post it straight here without completely re-writing it - cross-forum posting can get distorted by the differing forum software.]

I could not find your exact UserName in TenForums or I'd have posted it straight there for you.

All the best,
Denis
 

My Computer

System One

  • OS
    Windows 11 Home x64 Version 23H2 Build 22631.3447
@jaree1961 @Try3 Thanks to both of you. I just stumbled across elevenforum.com from a Google search. I probably should have made the logical leap that tenforum exists as well, haha.

Cheers!
 

My Computer

System One

  • OS
    Windows 10 & 11

Latest Tutorials

Back
Top Bottom