Skip to content

Latest commit

 

History

History
51 lines (30 loc) · 2.71 KB

AddShortcuts_with_Intune.md

File metadata and controls

51 lines (30 loc) · 2.71 KB

Step-by-step guide to run PowerShell scripts via Intune on Windows 10/11

This guide visually demonstrates steps described in Microsoft public documentation

Add PowerShell scripts to Windows 10/11 devices in Microsoft Intune

2. Select Devices > Scripts > Add > Windows 10 and later.

Intune_deploy_script1

3. In Basics, enter the following properties, and select Next:
  • Name: Enter a name for the PowerShell script.
  • Description: Enter a description for the PowerShell script. This setting is optional, but recommended.

Intune_deploy_script2

4. Specify the script file and configure the settings knobs as shown below

Intune_deploy_script3
"Script location:" set it to "AddShortcuts.ps1"
“Run this script using the logged-on credentials” set it to No
"Enforce script signature check" set it to No
"Run script in 64 bit PowerShell Host" set it to Yes

Note: Device targeting is preferred in case the end users are not logged on.

Note 2: You don't have to add "-MpTaskBarRecoverUtilDownload" since the Powershell script "AddShortcuts.ps1" will download the MPTaskBarRecover.exe by default.

Note 3: When running the AddShortcuts.ps1, you should consider using the -force switch.

5. “Add groups” select an AAD group for script targeting. You may want to select a group of test devices and users.

Intune_deploy_script4

6. Review all settings and “Add”

Intune_deploy_script5

7. Script created. Click on the script to monitor results

Intune_deploy_script6

8. Script results can be monitored in detail by browsing to “Device status”

Intune_deploy_script7

Note: For MEM (Intune) PowerShell script troubleshooting, review: C:\ProgramData\Microsoft Intune Management Extension\Logs\IntuneManagementExtension.log and C:\ProgramData\Microsoft\IntuneManagementExtension\Logs\AgentExecutor.log

For additional information and general troubleshooting of running PowerShell scripts via Intune please see product documentation at Add PowerShell scripts to Windows 10/11 devices in Microsoft Intune