Tag: Scripting

  • Script to Detect if Running from ConfigMgr Task Sequence and Avoid False Positives

    Overview This post shows how a script can detect if it is running from inside a Microsoft Configuration Manager Task Sequence in a way that avoids false positives. The Problem At times it’s useful for a script to detect if it is running from a ConfigMgr Task Sequence so it can alter its behaviour accordingly.…

    (Read more…)


  • AutoIt PowerShell Logo

    AutoIt Cmdlets for Windows PowerShell

    Overview The newest versions of the AutoIt scripting language now come with a bonus for PowerShell users. A set of native PowerShell Cmdlets! This allows you to add the unique features of AutoIt – window manipulation and keystroke simulation – to your usual PowerShell scripts. As an additional bonus, the AutoIt PowerShell Cmdlets and Assemblies…

    (Read more…)


  • Automating Office 365 Click-to-Run First Use Without Group Policy

    Overview This post shows how to automate the numerous “first-run” dialogs that are shown when a user runs an Office 2013 or Office 365 application for the first time. With a standard local installation of Office 2013 this can be done in two ways. Firstly, by using Group Policy (the recommended way). Secondly, by using…

    (Read more…)


  • Development

    Get the Current Script Directory in PowerShell, VBScript and Batch

    Overview This post shows how to quickly get the current script directory using PowerShell, VBScript and Batch – the most commonly used scripting languages for Windows. The scripts I write usually read in other files or call other scripts. In order for these scripts to run from any location – such as a UNC path…

    (Read more…)


  • Mass Redistribute Packages in ConfigMgr 2012

    Overview Recently I came across an issue with System Center Configuration Manager (ConfigMgr) 2012 where a large number of packages and applications had failed to be distributed to a new Distribution Point (DP). There were many thousands of packages in the environment and a few hundred were showing in the error state in the console.…

    (Read more…)


  • Detect an SSD Disk Using a Script

    Overview A common request when creating automated desktop builds or custom maintenance tools is the ability detect if the main system drive is an SSD disk or not. This information can be used to configure a system in a particular way. For example, to run (or not run) certain maintenance tasks or to optimally configure…

    (Read more…)