How to Deploy VBScript for Intune Application Installation

Let’s learn how you can deploy VBScript for Intune Application Installation. In this post, you will see how to use VBScript from Intune to install an application from Intune portal.

The ability to deploy a Win32 application from Intune is a much-used feature because it enables you to achieve many use cases. Using the Vbs deployment directly will reduce the work for the SCCM packager if transitioning from SCCM to Intune with the existing package prepared in VBScript.

The Application deployed using the VBScript gets automatically installed on Intune managed devices. You will experience the process remaining the same for application deployment except for the command line parameters, It will be easier to handle the deployment for the Application packager.

Before adding a Win32 app to Microsoft Intune, you must prepare the app using the Microsoft Win32 Content Prep Tool. You use the Microsoft Win32 Content Prep Tool to pre-process Windows classic (Win32) apps, Intune Win32 App Deployment Step By Step Guide. 

Patch My PC

Microsoft Intune company portal provides many branding options for Applications to provide a better user experience. Here you can check how Intune App deployed to the machine to display featured apps.

Prepare VBScript for Application Installation

We have seen many organizations using the VBScript method to wrap up the application for deployment. You must create a VB script that performs all the necessary actions. Once you have done this, Your folder structure should appear like this. For Example, I am installing the WinAuth application here.

You can also add the VBS installer in the batch file (.cmd or .bat) that can be used later during the application creation process using Intune.

Prepare VBScript for Apps - Deploy VBScript for Intune Application Installation Fig.1
Prepare VBScript for Apps – Deploy VBScript for Intune Application Installation Fig.1

The next step is to convert your files to .intunewin for uploading in Intune and start app creation using Win32 App. Download the updated IntuneWinAppUtil.exe from GitHubRun IntuneWinAppUtil.exe file Run as administrator.

Adaptiva
  • Please specify the source folder – Enter the folder that contains your application setup files. (For Example, C:\WinAuth)
  • Please specify the setup file – Enter the setup file name (such as setup.exe or setup.msi) For Example, WinAuth_3.5.1_x86x64_EN.msi
  • Specify the output folder – Input the output folder to generate the .intunewin file.
  • Do you want to specify catalog folder – Type N.
Convert Intunewin file - Deploy VBScript for Intune Application Installation Fig.2
Convert Intunewin file – Deploy VBScript for Intune Application Installation Fig.2

NOTE! Please wait a few minutes while running the Win32 Content Prep Tool. Once it generates the .intunewin file, the status indicates 100% at the bottom of the command prompt.

Once the process completes, Browse to the output folder to collect the Intune Win32 app deployment file.

Deploy VBScript for Intune Application Installation

Let’s follow the steps below to upload the Intunewin file for deploying WinAuth to managed devices. Here’s how you can deploy WinAuth VBScript installer using Intune.

  • Sign in to the Microsoft Intune admin center https://intune.microsoft.com/
  • Select Apps > All apps > Add, or you can navigate to Apps > Windows > Windows Apps.
  • On the Select app type pane, select Windows app (Win32) under the Other app types and click Select.
Deploy VBScript for Intune Application Installation Fig.3
Deploy VBScript for Intune Application Installation Fig.3

On the Add app pane, click Select app package file. Select the browse button. Then, select the prepared file with the extension .intunewin. The app details appear. When you’re finished, select OK on the App package file pane.

Deploy VBScript for Intune Application Installation Fig.4
Deploy VBScript for Intune Application Installation Fig.4

Enter the Name of the Windows App Win32 (For Example, WinAuth), and Enter the Description of the Windows App.

Enter the Publisher name, and You may specify the additional app information here. Upload an icon for the app. This icon is displayed with the app when users browse the company portal and click Next.

Deploy VBScript for Intune Application Installation Fig.5
Deploy VBScript for Intune Application Installation Fig.5

The most important part is to specify the commands. On the Program, configure the app installation and removal commands for the app:

  • Install base: Add the complete installation command line to silent install. For Example, cscript.exe Install.vbs
  • Uninstall command: Add the uninstallation command line. For Example, cscript.exe UnInstall.vbs
  • Install behavior: Set the install behavior to System.

You can also specify the Device restart behavior and Post-installation behavior. Click Next to continue.

Deploy VBScript for Intune Application Installation Fig.6
Deploy VBScript for Intune Application Installation Fig.6

On the Requirements page, specify the mandatory requirements that devices must meet before installing the update and click Next.

  • Operating system architecture: Choose the architectures needed to install WinAuth.
  • Minimum operating system: Select the minimum operating system needed to install WinAuth.

There are some built-in and custom requirements rules when creating your Win32 application. Explore Intune Win32 App Requirement Rules.

Deploy VBScript for Intune Application Installation Fig.7
Deploy VBScript for Intune Application Installation Fig.7

On the Detection rules pane, configure the rules to detect the presence of the app. You can choose to add multiple rules.

Here I selected the Manually configure detection rules format. Click on Add button, and A popup will appear showing the Detection rule. This detection rule format provides three detection rules MSIFile, and Registry.

Here you can check the registry path for the applications. Most apps are installed in the same location depending on the app architecture – Detection Method for Intune Win32 AppFor Example, Here, Check for MSI.

Deploy VBScript for Intune Application Installation Fig.8
Deploy VBScript for Intune Application Installation Fig.8

You can also specify app dependencies where the applications must be installed before your Win32 app can be installed.

In the scope tag section, you shall get an option to Configure scope tags for this Windows App Win32 application.

Under Assignments, In Included groups, click Add groups and then choose Select groups to include one or more groups to which you want to deploy the Windows Update. Click Next to continue.

Deploy VBScript for Intune Application Installation Fig.9
Deploy VBScript for Intune Application Installation Fig.9

You will see the details you provided during the application creation process. Review your settings and select Create to add the app to Intune.

Deploy VBScript for Intune Application Installation Fig.10
Deploy VBScript for Intune Application Installation Fig.10

Once you proceed to create, you will see the status Uploading is in progress, If you thinking about how much time will it take to complete the upload? It depends on the size of the application and the speed of internet connectivity.

Please wait some time to complete the upload process, and you can check the progress by clicking on the Notification icon. Once the intune package is uploaded and finished, you will get the status “Upload finished.”

End User Experience – Application Installation Status from Company Portal

Your groups will receive targeted applications when the devices check in with the Intune service the policy applies to the device.

On the client machine, In the Company Portal, You can click on the apps to track the details and check the progress. Here you can see that WinAuth is installed successfully.

Monitor WinAuth Deployment - Deploy VBScript for Intune Application Installation Fig.11
Monitor WinAuth Deployment – Deploy VBScript for Intune Application Installation Fig.11

Monitor WinAuth Deployment

To monitor the application installation from Intune Portal, select the application, and here you can check the device and user check-in status. If you click on Device install status for this application, additional details are displayed.

How to Deploy VBScript for Intune Application Installation 1
Deploy VBScript for Intune Application Installation Fig.12

Track Application Installation Status

Let’s check the Application Deployment status from the logs in the client machine. To confirm the application has been installed successfully, you can also check it in Event Viewer or Registry.

You can track the details logged at IntuneManagementExtension.log located C:\ProgramData\Microsoft\IntuneManagementExtension\Log. You track the application activity in client devices. You can check Intune Win32 App Issues Troubleshooting for more details.

Once the application installation starts, the “Detection rule” will be evaluated. Checks were performed against the rules configured, and the app “Install command” will be triggered.

<![LOG[Get policies = [{"Id":"13aec7ed-4841-4bee-99b1-2776a6bea615","Name":"WinAuth","Version":1,"Intent":3,"TargetType":2,"AppApplicabilityStateDueToAssginmentFilters":null,"AssignmentFilterIds":null,"DetectionRule":"[{\"DetectionType\":1,\"DetectionText\":\"{\\\"ProductCode\\\":\\\"{714D024C-E3FD-49D7-A8A8-B0BF0B6BCA2C}\\\",\\\"ProductVersion\\\":null,\\\"ProductVersionOperator\\\":0}\"}]","InstallCommandLine":"cscript.exe Install.vbs","UninstallCommandLine":"cscript.exe UnInstall.vbs"
Track Application Installation Status - Deploy VBScript for Intune Application Installation Fig.13
Track Application Installation Status – Deploy VBScript for Intune Application Installation Fig.13

Troubleshooting Win32 App References

For troubleshooting Intune client-side events, you can refer to three logs in case you experience any issues while deploying the Win32 app using Intune.

  • IntuneManagementExtension.log: Tracks the Intune Management extension component events.
  • AgentExecuter: Track any PowerShell execution events.
  • ClientHealth.log:  Track client-health related events.

Let’s learn Intune Win32 App Troubleshooting Client-Side Process Flow. You can look at the Level 3 deep dive troubleshooting Intune Management Extension (IME) Level 3 Troubleshooting Guide.

Author

Leave a Comment

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