A new piece of code solved this issue:
$CPApplet = New-Object -Comobject CPApplet.CPAppletMgr
$Actions = $CPApplet.GetClientActions()
ForEach ($Action in $Actions)
{
$Action.PerformAction()
}
Thanks!
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hello all,
I have created a script to run the SCCM Client Actions. I receive an 'access denied' when running as a standard user (non admin rights):
Script:
Clear-Host
$SCCMID = "{00000000-0000-0000-0000-000000000001}"
$params = @{
'Namespace' = 'root\CCM'
'ClassName' = 'SMS_Client'
'MethodName' = 'TriggerSchedule'
'Arguments' = @{ sScheduleID = $SCCMID }
}
Invoke-CimMethod @params
Invoke-WMIMethod -Namespace root\ccm -Class SMS_CLIENT -Name TriggerSchedule $SCCMID
The output:
Invoke-CimMethod : Access denied
At line:9 char:1
Invoke-WMIMethod : Access denied
At line:12 char:1
My question is: is there a way to run these commands as a regular - non admin - user? Feedback is appreciated.
With kind regards,
TheStingPilot
A new piece of code solved this issue:
$CPApplet = New-Object -Comobject CPApplet.CPAppletMgr
$Actions = $CPApplet.GetClientActions()
ForEach ($Action in $Actions)
{
$Action.PerformAction()
}
Thanks!
Hi,
We think these commands cannot be run as a regular user. But you can post the issue in some third-party forums, users there may have a solution.
Here are some of them
Please note: Information posted in the given link is hosted by a third party. Microsoft does not guarantee the accuracy and effectiveness of information.
----------
If the Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.