In earlier posts we saw how we can deploy Office 365 Pro Plus app to client devices. We also saw how we can deploy PowerShell scripts to configure certain settings.

In this post we’ll see how we can create a simple Win32 app. This Win32 app does one simple task, Copy certain required files to target devices.

These files will be used in further configurations. Also we’ll continue to update the app with new files as and when needed.

Existing setup done:

  1. Two Local users created
  2. Azure AD Connect configured
  3. Seamless Single Sign-On (IE) configured
  4. Seamless Single Sign-On (Firefox) configured
  5. Hybrid Azure AD Join configured
  6. Intune enrollment – Domain Joined Windows 10 devices
  7. Azure AD Join
  8. Office 365 Pro Plus Application
  9. Sample SharePoint Team Site
  10. OneDrive Known Folder Migration and SharePoint library sync

Existing setup:

  1. SkyDC: Machine with ADDS, DNS, DHCP role
  2. SkyCON: Machine where we will install Azure AD Connect
  3. SkyCM: Machine with Configuration Manager Current Branch
  4. SkyTEN1: Domain Joined Windows 10 machine
  5. SkyTEN2: Domain Joined Windows 10 machine
  6. SkyTEN3i: Domain Joined Windows 10 machine (Intune Managed)
  7. SkyTEN4i: Domain Joined Windows 10 machine (Intune Managed)
  8. SkyTEN5i: Azure AD Joined Windows 10 (Intune Managed)
  9. SkyTEN6i: Azure AD Joined Windows 10 (Intune Managed)
  10. SkyTEN7i: Azure AD Joined Windows 10 (Cloud User, Intune Managed)
  11. SkyTEN8i: Azure AD Joined Windows 10 (Cloud User, Intune Managed)

Create a Win32 app package

Make a list of all necessary files that you want to copy to targeted devices.

Create a folder and put all files in that folder


Microsoft Edge.lnk




Create a CMD file which will copy all files to Windows folder:

copy /Y .\”Microsoft Edge.lnk” %systemRoot%\

copy /Y .\Sky366.scr %systemRoot%\

copy /Y .\Sky366BG.png %systemRoot%\

copy /Y .\Sky366LS.png %systemRoot%\

Create another folder where Win32 app will be created.

Navigate to Click on Clone or download and click on Download ZIP.

Save the file and extract the contents.

The extracted contents.

Open Command Prompt. Navigate to the folder where Win32 Content Prep Tool is extracted and execute IntuneWinAppUtil.exe

Enter relevant details and press Enter. I have used the below:

Please specify the source folder: D:\Tenants\Sky366\Apps\CopyFiles

Please specify the setup file: copyFiles.cmd

Please specify the output folder: D:\Tenants\Sky366\Apps\Win32Apps

You can see the tool executed successfully.

The Win32 App is created with extension .intunewin

Create an Win32 App in Intune

Login to Azure portal.

Navigate to Intune -> Client apps -> Apps. Click on +Add.

In App type, select Windows app (Win32).

Click on App package file – Select file.

Click on the folder icon and select the .Intunewin file

Click OK.

Click on App information – Configure.

Enter the details and click OK. I have used below

Name: Copy Files

Description: This App will copy the necessary files in the target device.

Publisher: Your Organization

Click on Program – Configure.

In Install command, enter the CMD file which will copy the files.

In Uninstall command, enter the CMD file which will copy the files. Note: As I am not going to use Uninstall command, I have used the same CMD file. You can create another CMD file in the same folder which will delete the files from the Windows folder and mention it here.

In Install behavior, select System.

Click OK.

Click on Requirements – Configure.

In Operating system architecture, select both the architecture.

In Minimum operating system, select the appropriate option.

I have selected the Windows 10 1607.

Click OK.

Click Detection rules – Configure.

In Rules format, select Manually configure detection rules. Click Add.

Note: if any of the files in the app exists in the Windows folder, then app is already run. So, we’ll check for one file’s existence.

In Rule type, select File.

In Path, enter %SystemRoot%

In File or folder, enter one of the filename with extension. I entered Sky366.scr.

In Detection method, select File or folder exists.

In Associated with a 32-bit app on 64-bit clients, select No.

Click OK.

Click OK.

Click Add.

After some time, you’ll see that the file is uploaded successfully.

Open the App again.

Navigate to Assignments.

Click on Add group.

In Assignment type, select Required.

Click on Include Groups.

Choose appropriate option.

I am making the app required for all devices.

Click Save.

In Client machine:

In client machine, to get the result immediately, sync the device.

After some time you’ll see the files in Windows folder.

1 Comment

  1. Yashpal Rajput


    Thanks for your Very Good Article on Files and Folders Copy for the Intune Managed Devices over the internet.

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.