none
How to push PowerShell CMDLET thru Group Policy

All replies

  • Hi,

    pretty straight-forward. Save it as a PowerShell script (.ps1) and put it in a policy. Here is a guide on how to do this:

    Configuring logon PowerShell scripts with Group Policy

    Hope this helps. Regards,


    Stoyan (Please take a moment to "Vote as Helpful" and/or "Mark as Answer" where applicable. This helps the community, keeps the forums tidy, and recognizes useful contributions. Thanks!)


    • Edited by Stoyan ChalakovMVP Friday, November 11, 2016 12:42 PM
    • Proposed as answer by jrv Friday, November 11, 2016 4:23 PM
    Friday, November 11, 2016 12:42 PM
  • Hi

    I asked about PowerShell CMDLet or compiled exe file. What ever you suggested it is for powershell script ,is this same process applicable for powershell compiled exe.

    Avian

    Friday, November 11, 2016 1:53 PM
  • Hi

    I asked about PowerShell CMDLet or compiled exe file. What ever you suggested it is for powershell script ,is this same process applicable for powershell compiled exe.

    Avian

    CmdLets cannot be independently deployed.  Scripts can.

    I recommend that first you learn a bit about PowerShell so you will understand what it is and how to create a PowerShell script.


    \_(ツ)_/

    Friday, November 11, 2016 4:23 PM
  • Hi,
    As jrv said, the cmdlets might be not able to be pushed via group policy. However, we could install the PowerShell modules for all users which list the cmdlets and variables, in this case, you could refer to the following article for the suggested methods to have a try:
    Installing PowerShell module persistently for all users
    http://stackoverflow.com/questions/20885398/installing-powershell-module-persistently-for-all-users
    Please Note: Since the web site is not hosted by Microsoft, the link may change without notice. Microsoft does not guarantee the accuracy of this information.
    Best regards,
    Wendy

    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Monday, November 14, 2016 6:08 AM
    Moderator