Setting computer time with Invoke-WmiMethod

I’m having difficulties setting up the time on remote computers using Invoke-WmiMethod, I can’t use PSRemoting so bear with me, the docs say the method (SetDateTime) takes an integer, however, no matter what I do I get a ‘Type mismatch’ or ‘Value to large or small’ error, so, what am I doing wrong? I’ve searched the interwebz and the solutions I found didn’t work either.

What do I put in Argument List?:
Invoke-WmiMethod -Class Win32_OperatingSystem -ComputerName SomePCName -ArgumentList ???

Argument list is the arguments for the method you invoke.


$r = Get-WmiObject -Class win32_Service -Filter "Name='BITS'"
$r.ChangeStartMode # Method to change start mode
$r.ChangeStartMode("Manual")  #this is how we use the method to change the start mode.

#using Invoke-WmiMethod

$r | Invoke-WmiMethod -Name ChangeStartMode -ArgumentList Manual