Can WMI do this?

Set the page file so the system will manage it. I found this script but, it hard sets the page file.

VB Code:
  1. strComputer = "."
  2. Set objWMIService = GetObject("winmgmts:" _
  3.     & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
  4.  
  5. Set colPageFiles = objWMIService.ExecQuery _
  6.     ("Select * from Win32_PageFileSetting")
  7.  
  8. For Each objPageFile in colPageFiles
  9.     objPageFile.InitialSize = 300
  10.     objPageFile.MaximumSize = 600
  11.     objPageFile.Put_
  12. Next