Change OpenRGB profile on unlock

I have a computer, which my son uses primarly for gaming. I also use it for gaming, when it is available (as of right now, when he has gone to bed). The computer is pimped out with RGB. I got tired of Asus Armoury Crate every now and then maxing the CPU causing the fans to make too much noice, so I replaced it with OpenRGB.

OpenRGB is started automagically when either of us logs in, and sets our own profile. The problem was when we switched between users the last logged in users profile would be the active one.

A combination of a VB script and a scheduled task solves this problem. Create a color profile in OpenRGB and save it with a good name (preferably without spaces).

As an example, create C:\OpenRGB.vb with the following contents:
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.CurrentDirectory = "C:\Program Files\OpenRGB\"
WshShell.Run "OpenRGB.exe --profile ""my-openrgb-profile""", 0, false

Then create a scheduled task that is trigger on workstation unlock and runs the C:\OpenRGB.vb script, something like:
<?xml version="1.0" encoding="UTF-16"?>
<Task version="1.2" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task">
<RegistrationInfo>
<Date>2023-01-13T21:39:19.3700162</Date>
<Author>COMPUTER\User Name</Author>
<URI>\OpenRGB</URI>
</RegistrationInfo>
<Triggers>
<SessionStateChangeTrigger>
<Enabled>true</Enabled>
<StateChange>SessionUnlock</StateChange>
<UserId>COMPUTER\User Name</UserId>
</SessionStateChangeTrigger>
</Triggers>
<Principals>
<Principal id="Author">
<UserId>S-1-5-21-775115785-2816134056-1390457888-1001</UserId>
<LogonType>InteractiveToken</LogonType>
<RunLevel>LeastPrivilege</RunLevel>
</Principal>
</Principals>
<Settings>
<MultipleInstancesPolicy>IgnoreNew</MultipleInstancesPolicy>
<DisallowStartIfOnBatteries>true</DisallowStartIfOnBatteries>
<StopIfGoingOnBatteries>true</StopIfGoingOnBatteries>
<AllowHardTerminate>true</AllowHardTerminate>
<StartWhenAvailable>false</StartWhenAvailable>
<RunOnlyIfNetworkAvailable>false</RunOnlyIfNetworkAvailable>
<IdleSettings>
<StopOnIdleEnd>true</StopOnIdleEnd>
<RestartOnIdle>false</RestartOnIdle>
</IdleSettings>
<AllowStartOnDemand>true</AllowStartOnDemand>
<Enabled>true</Enabled>
<Hidden>false</Hidden>
<RunOnlyIfIdle>false</RunOnlyIfIdle>
<WakeToRun>false</WakeToRun>
<ExecutionTimeLimit>PT72H</ExecutionTimeLimit>
<Priority>7</Priority>
</Settings>
<Actions Context="Author">
<Exec>
<Command>C:\OpenRGB.vbs</Command>
</Exec>
</Actions>
</Task>

Now I just need QMK to finish their new client protocol XAP, and for OpenRGB to implement support for that protocol so it also can control the RGB lightning on the keyboard.