Application folders in MDT 2010 + PowerShell

One nice thing with MDT 2010 is the possibility to
make folders in the Application folder.

I like a nice structure of things and with PowerShell
I can make my structure for MDT 2010 Applications,
Operating Systems and Drivers in no time.

image

cls
$MDTName = "MyMDT"
$MDTServer = "\\padc01"
$MDTApplications = "Antivirus", "Browser", "Office", "Twitter", "Security", "Server"
Add-PSSnapIn Microsoft.BDD.PSSnapIn
New-PSDrive -Name $MDTName -PSProvider MDTProvider -Root $MDTServer\DeploymentShare$
foreach ($MDTApp in $MDTApplications) {
    New-Item -path "$MDTName:\Applications" -enable "True" -Name "$MDTApp Applications"
 -Comments "$MDTApp Applications" -ItemType "folder" -Verbose -ErrorAction SilentlyContinue
}

9 lines of code can make 50 folders in 50 sec :)

And you can make it in less lines!

 

Technorati Tags: ,

No related posts.

This entry was posted in PowerShell Blogs and tagged , . Bookmark the permalink.

3 Responses to Application folders in MDT 2010 + PowerShell

  1. Fredrik Wall says:

    [Blog] Application folders in MDT 2010 + PowerShell: One nice thing with MDT 2010 is the possibility to make fol… http://bit.ly/4sIQOP

  2. Fredrik Wall says:

    [Blog] Application folders in MDT 2010 + PowerShell: One nice thing with MDT 2010 is the possibility to make fol… http://bit.ly/4sIQOP

  3. MI Trade says:

    Application folders in MDT 2010 + PowerShell | Dalle & DXter http://ow.ly/ZRLr

Leave a Reply

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

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>