March, 2010

  • Michael Niehaus' Windows and Office deployment ramblings

    Hiding (and showing) the task sequence progress dialog box

    • 4 Comments

    fThe task sequencer used in MDT 2010 and ConfigMgr 2007 is designed to show you at all times what’s going on with your task sequence:

    image

    As a result, it forces this dialog to be on the top of all other windows, which can be annoying in some situations because you want to get this out of the way.  I’ve seen various solutions for this, typically that just move the dialog out of the way (to the edge of the screen, off the screen, etc.).  But there’s a much easier way to do this:  you can just tell this dialog to close itself using a very simple script:

    ' Hide the progress dialog

    Set oTSProgressUI = CreateObject("Microsoft.SMS.TSProgressUI")
    oTSProgressUI.CloseProgressDialog
    Set oTSProgressUI = Nothing

    That causes the progress dialog to close (not surprisingly) – at least until it is told to update the progress, something that would typically happen at the start of the next step.  So it’s only gone temporarily, but that’s OK – in most cases, you just want it to be gone for one step anyway, so have that step run a VBScript that hides the dialog, does its work, and then exits.

    If you did want the progress dialog to show up again before the next step, you can force a progress update.  If you are referencing the MDT ZTIUtility.vbs script, this is pretty simple too because it already has a function to do this.  Just include logic like this:

    ' Report progress to get the dialog to show up again

    oLogging.ReportProgress "Done", 100

    If you aren’t using ZTIUtility.vbs, you can add some logic like this:

    Public Function OpenProgressDialog

        Dim oProgress
        Dim uStep
        Dim uMaxStep

        ' Try to create the progress UI object

        On Error Resume Next
        Set oProgress = CreateObject("Microsoft.SMS.TSProgressUI")
        If Err then
            Err.Clear
            Exit Function
        End if
        On Error Goto 0

        ' Update the progress

        On Error Resume Next

        uStep = CLng(oEnvironment.Item("_SMSTSNextInstructionPointer"))
        uMaxStep = CLng(oEnvironment.Item("_SMSTSInstructionTableSize"))
        Call oProgress.ShowTSProgress(oEnvironment.Item("_SMSTSOrgName"), oEnvironment.Item("_SMSTSPackageName"), oEnvironment.Item("_SMSTSCustomProgressDialogMessage"), oEnvironment.Item("_SMSTSCurrentActionName"), (uStep), (uMaxStep))

        On Error Goto 0

        ' Dispose of the object

        Set oProgress = Nothing

    End Function

    If using ZTIUtility, the complete script could look like this:

    <job id="Scripting201">
       <script language="VBScript" src="ZTIUtility.vbs"/>
       <script language="VBScript">

        ' Hide the progress dialog

        Set oTSProgressUI = CreateObject("Microsoft.SMS.TSProgressUI")
        oTSProgressUI.CloseProgressDialog
        Set oTSProgressUI = Nothing

        ' <Do your work here>

        ' Show the progress dialog (using one of these methods) if you don't want to wait

        oLogging.ReportProgress "Done", 100

        ' <Maybe do some more work>

       </script>
    </job>

    If you aren’t using ZTIUtility.vbs, it gets a little longer:

    <job id="Scripting201">
       <script language="VBScript">

        ' Hide the progress dialog

        Set oTSProgressUI = CreateObject("Microsoft.SMS.TSProgressUI")
        oTSProgressUI.CloseProgressDialog
        Set oTSProgressUI = Nothing

        ' <Do your work here>

        ' Show the progress dialog (using one of these methods) if you don't want to wait

        OpenProgressDialog

        ' <Maybe do some more work>

        ' The OpenProgress Dialog method gets the dialog to show up again

        Public Function OpenProgressDialog

            Dim oProgress
            Dim uStep
            Dim uMaxStep

            ' Try to create the progress UI object

            On Error Resume Next
            Set oProgress = CreateObject("Microsoft.SMS.TSProgressUI")
            If Err then
                Err.Clear
                Exit Function
            End if
            On Error Goto 0

            ' Update the progress

            On Error Resume Next

            uStep = CLng(oEnvironment.Item("_SMSTSNextInstructionPointer"))
            uMaxStep = CLng(oEnvironment.Item("_SMSTSInstructionTableSize"))
            Call oProgress.ShowTSProgress(oEnvironment.Item("_SMSTSOrgName"), oEnvironment.Item("_SMSTSPackageName"), oEnvironment.Item("_SMSTSCustomProgressDialogMessage"), oEnvironment.Item("_SMSTSCurrentActionName"), (uStep), (uMaxStep))

            On Error Goto 0

            ' Dispose of the object

            Set oProgress = Nothing

        End Function

       </script>
    </job>

  • Michael Niehaus' Windows and Office deployment ramblings

    Speaking at MMS 2010

    • 0 Comments

    I guess I’ll be fairly busy at MMS 2010, from April 19-23rd in Las Vegas.  These are the sessions I’ll be presenting:

    BC07 Troubleshooting Windows 7 Deployments

    Thursday 10:15 AM - 11:30 AM, Titian 2203-2304 

    When everything works, Windows 7 deployment is great. But what about when things break? In this session, we'll look at common causes and solutions for failed Windows 7 deployments, looking at issues with the Windows 7 installation process itself (SETUP and related tools), Microsoft Deployment Toolkit 2010 (Lite Touch), and ConfigMgr 2007 SP2 (Zero Touch).

    BC32 A Drivers Saga - The Control Freak meets The Dynamic Developer

    Wednesday 11:45 AM - 1:00 PM, Titian 2203-2304 

    Speaker(s): Johan Arwidmark, Michael Niehaus

    One of the biggest challenges when doing windows deployment is dealing with device drivers. Meet Michael Niehaus and Johan Arwidmark sharing their notes from the field around handling device drivers in the deployment process. As a foundation the MDT 2010 and ConfigMgr 2007 SP2 platform will be used. You can expect a lot of live demos, tips and tricks in this session.

    BE04 Enabling Dynamic Windows 7 Deployments with Configuration Manager 2007 and MDT 2010

    Thursday 4:00 PM - 5:15 PM, Bellini 2105-2106 

    See how to leverage Configuration Manager 2007 SP2 and MDT 2010 together to perform dynamic Windows 7 deployments - without the need for multiple images or task sequences. This session will explore the basics of using Configuration Manager 2007 for Windows 7 deployment, as well as exploring the value-added capabilities which the Microsoft Deployment Toolkit 2010 solution accelerator (a free add-on for ConfigMgr) provides.

    BG01 MDT 2010 Update 1 + ConfigMgr 2007 OSD: Even More "Better Together"

    Thursday 2:30 PM - 3:45 PM, Titian 2201-2302 

    Microsoft Deployment Toolkit 2010 integrates with System Center Configuration Manager 2007 to provide additional functionality over and above the standard OS deployment features. In this session, we will quickly review this additional functionality, and then will focus on the new enhancements coming in MDT 2010 Update 1, including:

    • Support for ConfigMgr R3's OEM pre-staged media
    • The new user-driven OS deployment task sequence template
    • Offline user state capture from Windows PE
    • Other miscellaneous enhancements and fixes
    We will also hear how Microsoft IT leveraged the user-driven OS deployment task sequence template internally to enable self-service OS deployment with ConfigMgr.

     

    Related to session BC07, please e-mail me at mniehaus@microsoft.com if you have any specific issues that you’ve encountered in your Windows 7 deployments, whether they are related to Windows, MDT 2010, or ConfigMgr.  I want to try to go through as many of these as possible during the session.  (I’ve got lots of examples in my inbox, but it’s always challenging to figure out which of those issues are actually something others in the “real world” will encounter.)

    Also notice that the BC32 session will be presented by both myself and Johan Arwidmark.  (In case you’re wondering, he’s the control freak, I’m the dynamic developer.)  We’ll try our best to not argue on stage…

    For those that have been wondering about Modena, session BG01 will explore that:  “User-Driven” OS deployment using ConfigMgr.

Page 1 of 1 (2 items)