Unable to create win8.1 media error: Unable to cast object of type.... RRS feed

  • Question

  • Hi guys,

    Was hoping you could help shed some light on my issue. This is my first time creating a deployment for Win 8.1, normally I do Win 7 with MDT 2012 update 1.

    Anyways, I am using a new setup, with MDT 2013, added win 8.1 OS, created a task sequence, and added a set of drivers. I made sure I have the ADK x64 installed correctly. I made sure the appropiate versions of .NET was installed and updated.

    I am currently failing at creating media in my deployment share. I don't have a server setup, I simply have a Win 8.1 deploy share that is setup exactly the same way I did the Win 7 deploy share, but yet I cannot create media.

    The error I get is "Unable to cast object of type 'System.Management.Automation.Runtime..." as below:


    Can someone help as to why I get this error, and how to fix it?



    Thursday, May 14, 2015 8:06 PM

All replies

  • Can I get more details?

    Server OS
    Version of ADK

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

    Thursday, May 14, 2015 9:06 PM
  • Did you previously have WAIK? Did you remove it prior to installing ADK?

    If this post is helpful please vote it as Helpful or click Mark for answer.

    Thursday, May 14, 2015 9:51 PM
  • Try running this process on a PC running Windows 8.1, of course with ADK 8.1

    - Yannick Plavonil

    Deploiement Windows

    Saturday, May 16, 2015 5:27 PM
  • I too am seeing the exact same message.  Running MDT 2013 (6.2.5019.0), ADK for Win 8.1, on a Windows 8.1 x64 workstation.  I might have had WAIK, but that it would have been a while ago.  I uninstalled/reinstalled MDT 2013 and Windows ADK this morning, so I know that I am running the latest (non-Preview) builds.

    Full error output:

    Starting MDT Media Update
    Opened the media deployment share.
    Folders to be copied to the media deployment share: 6

    System.Management.Automation.CmdletInvocationException: Unable to cast object of type 'System.Management.Automation.RuntimeDefinedParameterDictionary' to type 'Microsoft.PowerShell.Commands.CopyItemDynamicParameters'. ---> System.InvalidCastException: Unable to cast object of type 'System.Management.Automation.RuntimeDefinedParameterDictionary' to type 'Microsoft.PowerShell.Commands.CopyItemDynamicParameters'.
       at System.Management.Automation.SessionStateInternal.CopyItem(String[] paths, String copyPath, Boolean recurse, CopyContainers copyContainers, CmdletProviderContext context)
       at Microsoft.PowerShell.Commands.CopyItemCommand.ProcessRecord()
       at System.Management.Automation.CommandProcessor.ProcessRecord()
       --- End of inner exception stack trace ---
       at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
       at Microsoft.BDD.Wizards.GenerateMediaProgress.WizardProcessing()
       at Microsoft.BDD.Wizards.WizardProgress.InitiateWizardProcessing()

    Any suggestions?



    • Edited by JPopik Tuesday, June 2, 2015 5:18 PM
    Tuesday, June 2, 2015 4:59 PM
  • Hi James,

    I just experienced the same issue. It seemed to be caused by the PoSH version installed on my lab box. I was using the Windows Management Framework 5.0 Preview. Once I uninstalled this and got back to PoSH v4.0 on my Windows 8.1 box i was able to update the media. 

    Hope that helps...

    Gabe | @ConfigMgrGeek

    Tuesday, July 14, 2015 8:40 PM