MDT Debugger 2.0

Back in March of last year, I posted the MDT Debugger as a time/stress and frustration saving tool useful for debugging the scripts you develop for use with MDT.  Over the last year, I've used the tool in every MDT project that I have worked on, which has given me the opportunity to (very slowly) address the shortcomings that it has.  Thanks to this, I have been able to work on an updated version and as such: welcome to MDT Debugger 2.0!

I actually ended up rewriting the tool using the excellent AutoIT rather than trying to update the existing HTML code as this gave a lot more flexibility and in itself solved a few of the "issues" the version 1.0 had.  This new version has the following improvements:

  • Allows editing the command-line received from MDT
  • Being an executable rather than HTML, it no longer clashes with strict Internet Explorer security settings, nor with the Internet Explorer first-run wizard
  • Works in Windows PE (WinPE)
  • Capture and redirection of script output to the debugging window
  • Better handling of command line parameters
  • Faster execution time 


MDT Debugger 2.0


To use the new MDT Debugger, download the attached zip file and extract its contents to your MDT deployment share (I always place both files directly in the Scripts folder).  Then, open the MDT Task Sequence editor and add the following command before the existing command line for any of your custom actions: "%SCRIPTROOT%\CUSTOM_MDTDebugger.exe".  For example:

  • Your existing command "cscript.exe %SCRIPTROOT%\CUSTOM_Script.wsf" becomes "%SCRIPTROOT%\CUSTOM_MDTDebugger.exe cscript.exe %SCRIPTROOT%\CUSTOM_Script.wsf"


As with the previous version, this tool will only work for LTI deployments because of the fact that it requires showing on the desktop a screen that the user will interact with - something that ZTI deployments are not too fond of.  Please let me know if you find any problems with it, or have any suggestions for changes!



This post was contributed by Daniel Oxley, a Consultant with Microsoft Services Spain

Disclaimer: The information on this site is provided "AS IS" with no warranties, confers no rights, and is not supported by the authors or Microsoft Corporation. Use of included script samples are subject to the terms specified in the Terms of Use