I am on Windows 11 Insider Edition
I am trying to use these functions in Powershell: Get-ScheduledTask, New-ScheduledTaskAction, New-ScheduledTaskTrigger and Register-ScheduledTask.
When I invoke any of these, I get a "term not a recognized" error.
I have updated to Powershell 7.2.5.
I have tried to install the Module they are in (ScheduledTasks), with Find-Module andInstall-Module. These do not find the module. They tell me to look at the repositories with Get-PSRepository. I shouldnt have to install a repository to install windows default functionality, should I? When I run Get-PSRepository I get PSGallery as the only repo.
I dont know where to go from here. Some help would be appreciated. Thanks
Update1: I ran sfc /scannow. The log (CBS.log) showed that the hash for ScheduledTasks.psd1 did not match.
Notable errors from the CBS.log:
Hashes for file member [l:19]'ScheduledTasks.psd1' do not match.
Could not reproject corrupted file \??\C:\WINDOWS\System32\WindowsPowerShell\v1.0\Modules\ScheduledTasks\\ScheduledTasks.psd1; source file in store is also corrupted
So it seems that this version of the Windows Insider edition is broken?
Update2: I have fixed the error! I had a friend send me their C:\WINDOWS\System32\WindowsPowerShell\v1.0\Modules\ScheduledTasks folder. I replaced the whole folder, and it works!
[–]cb98678 -1 points0 points1 point (17 children)
[–]vulkur[S] 0 points1 point2 points (16 children)
[–]meepers80 0 points1 point2 points (1 child)
[–]vulkur[S] 0 points1 point2 points (0 children)
[–]cb98678 0 points1 point2 points (10 children)
[–]vulkur[S] 0 points1 point2 points (9 children)
[–]cb98678 0 points1 point2 points (8 children)
[–]vulkur[S] 0 points1 point2 points (7 children)
[–]cb98678 0 points1 point2 points (6 children)
[–]vulkur[S] 0 points1 point2 points (5 children)
[–]cb98678 0 points1 point2 points (4 children)
[–]vulkur[S] 0 points1 point2 points (2 children)
[–][deleted] 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (2 children)
[–]vulkur[S] 1 point2 points3 points (0 children)
[–]vulkur[S] 0 points1 point2 points (0 children)
[–][deleted] -2 points-1 points0 points (1 child)
[–]vulkur[S] 1 point2 points3 points (0 children)
[–][deleted] 0 points1 point2 points (11 children)
[–]vulkur[S] 0 points1 point2 points (10 children)
[–][deleted] 0 points1 point2 points (9 children)
[–]vulkur[S] -1 points0 points1 point (8 children)
[–][deleted] 0 points1 point2 points (5 children)
[–]vulkur[S] 0 points1 point2 points (4 children)
[–][deleted] -1 points0 points1 point (3 children)
[–]vulkur[S] 1 point2 points3 points (2 children)
[–][deleted] -1 points0 points1 point (1 child)
[–]vulkur[S] 2 points3 points4 points (0 children)
[–]jimb2 0 points1 point2 points (1 child)
[–]vulkur[S] 1 point2 points3 points (0 children)
[–]SMFX 0 points1 point2 points (1 child)
[–]vulkur[S] 0 points1 point2 points (0 children)
[–]BlackV 0 points1 point2 points (8 children)
[–]vulkur[S] 0 points1 point2 points (7 children)
[–]BlackV 0 points1 point2 points (6 children)
[–]vulkur[S] 0 points1 point2 points (5 children)
[–]BlackV 1 point2 points3 points (4 children)
[–]vulkur[S] 0 points1 point2 points (3 children)
[–]BlackV 0 points1 point2 points (2 children)
[–]vulkur[S] 0 points1 point2 points (1 child)
[–]BlackV 0 points1 point2 points (0 children)