PowerShell

The PowerShell forum accepts bug reports as well as feedback and suggestions. For more information, check out the PowerShell Homepage

The following is a list of the states we use to track items.

status meaning
survey We saw this and we are considering it. Please upvote if it’s important to you.
needs more information We don’t understand the issue and need additional details.
investigating We are looking at this internally to understand things like: scenario, reproduction of issue, costing, or other technical details.
in queue The issue is understood and in our unprioritized backlog. Your votes will be used to drive prioritization of this work.

Please feel free to provide feedback or file bugs here.

(thinking…)

Enter your idea and we'll search to see if someone has already suggested it.

If a similar idea already exists, you can support and comment on it.

If it doesn't exist, you can post your idea so others can support it.

Enter your idea and we'll search to see if someone has already suggested it.

  • Hot ideas
  • Top ideas
  • New ideas
  • My feedback
  1. Start-Transcript does not capture user keyboard input when started from a script when ran under Powershell Version 5

    I have found after upgrading Windows Powershell from Version 4 to Version 5 that the transcript log file created by the Start-Transcript commandlet does not capture the users keyboard input....where it does capture user input when running in Version 4.

    Steps to replicate:

    1. Create a ps1 script with Start-Transcript and a Write-Host/Read-Host response. (Feel free to use the "script code" below)

    Start-Transcript C:\Temp\Test.log

    Write-Host "Enter your name: " -NoNewline
    $Name = Read-Host
    Write-Host
    Write-Host "You entered: $Name"

    2. Run the script on a machine with Windows Powershell 4 installed, review the Transcript log.

    3. Do the same on a…

    1 vote
    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)

      We’ll send you updates on this idea

      0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
    • Some Storage cmdlets do not work in WinPE

      At least Clear-Disk and New-Partition cmdlets from Storage module do not work in Windows PE. Nothing happens if you launch any of them, no any output/result. There may be more cmdlets not working in Windows PE.
      There is a topic on TechNet https://social.technet.microsoft.com/Forums/windowsserver/en-US/3a0e7e9c-f1ea-4324-8a17-f4c447efcbb0/some-storage-cmdlets-do-not-work-under-winpe?forum=winserverpowershell

      1 vote
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        I agree to the terms of service
        Signed in as (Sign out)

        We’ll send you updates on this idea

        0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
      • Start-Process is behaving strange when -credential switch is used

        When running Start-Process start-process "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -cred $(Get-Credential) regardless if the credentials differ from the current consoles credentials or the same credentials are used, the new console window seems to be unresponsive, until you switch back to the console from which the new console was launched and start typing something in that console.

        If the same thing is done in ISE, this issue does not occour.

        I have testet this on PS 5.1.14393.206, 5.1.14393.953 and 5.1.14393.693. Windows Server 2012R2, Windows Server 2016 and Windows 10

        Please see the issue in this video: https://goo.gl/8ZvdEV

        1 vote
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          I agree to the terms of service
          Signed in as (Sign out)

          We’ll send you updates on this idea

          0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
        • Get-WinEvent -ListLog fails for logs with invalid EVTX file paths

          When an event log has an invalid folder path to its EVTX log file, this command throws an exception and fails to read any data about that log from the registry, it simply skips that log object entirely:

          Get-WinEvent -ListLog *

          The error is "Get-WinEvent : Could not retrieve information about the Microsoft-Windows-RetailDemo/Operational log. Error: The system cannot find the path specified."

          The expected behavior is for Get-WinEvent to read the log information out of the registry, even if the log file path is invalid, and output an object with as much information as possible (and not just give up).…

          1 vote
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            I agree to the terms of service
            Signed in as (Sign out)

            We’ll send you updates on this idea

            0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
          • Get-WinEvent displays wrong MaximumSizeInBytes value

            On Vista and later, the maximum permissible Windows event log size is 18014398509481983 KB.

            When set to this value for the System log (and other logs too presumably) the following command fails to show the maximum log file size correctly:

            Get-WinEvent -ListLog System

            Specifically, the MaximumSizeInBytes value shown is -1024.

            Expected behavior is to show the current max size from the registry in bytes correctly, even if the value is absurdly large.

            A very large max value might be set accidentally or maliciously, and the bug may cause problems detecting or correcting it.

            The above behavior was tested on Windows…

            1 vote
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              I agree to the terms of service
              Signed in as (Sign out)

              We’ll send you updates on this idea

              0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
            • Copy with chinese string code from ise,paste it into WORD 2016,garbled

              【Bug to reproduce】
              Copy with chinese string code from powerGUI,paste it into word 2016,normal.
              Copy with chinese string code from ise,paste it into word 2016,garbled.

              ------------
              $a = 1
              $b = "字符串"
              # 汉字乱码
              ------------

              【old report link】
              https://connect.microsoft.com/PowerShell/Feedback/Details/2002528

              【powershell version】
              ise in windows 8.1
              ise in windows 10 14393.1066

              microsoft office 2016
              microsoft office 2013

              【reason】
              unknown

              【reporter】
              By the chinese powershell study & research group. QQ group No. is 183173532

              1 vote
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                I agree to the terms of service
                Signed in as (Sign out)

                We’ll send you updates on this idea

                0 comments  ·  ISE and tooling  ·  Flag idea as inappropriate…  ·  Admin →
              • Copy headers when copying from Out-GridView

                It would be great to copy headers for all the columns when copying data from the Out-GridView table lists.

                5 votes
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  I agree to the terms of service
                  Signed in as (Sign out)

                  We’ll send you updates on this idea

                  survey  ·  1 comment  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
                • Bug: DSC Decryption across Servers not Working

                  On 2 Fully Updated Windows Server 2016 Machines running and provisioned from Azure I have created a Pull Server Configuration. I have created the DSC Signing Certificate using a custom template on a Enterprise Root CA which has worked for 2012R2 nodes and also tested using xDSCUtils New-xSelfSignedDscEncryptionCertificate. Using the same Certificate to Compile and Execute the MOF on the same Computer works, it is only if you compile on one and execute on another that the problems arise.
                  I kept getting errors when passing in credentials. I therefore wrote a tiny custom DSC Resource that Displays the Password as…

                  1 vote
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    I agree to the terms of service
                    Signed in as (Sign out)

                    We’ll send you updates on this idea

                    investigating  ·  0 comments  ·  Desired State Configuration (DSC)  ·  Flag idea as inappropriate…  ·  Admin →
                  • ConvertToDateTime bug

                    The ConvertToDateTime() ScriptMethod is incorrect / broken and does NOT take into account the current time zone as defined by System.Management.ManagementDateTimeConverter.ToDateTime() method. In fact, it's not applying any time zone at all. But a confirmation of what it's really doing would be great. Full analysis and test scripts at my blog - https://goo.gl/b4ZTqf

                    1 vote
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      I agree to the terms of service
                      Signed in as (Sign out)

                      We’ll send you updates on this idea

                      0 comments  ·  WMI  ·  Flag idea as inappropriate…  ·  Admin →
                    • Bug: Here string - When using invoke-command when here string starts with [

                      Using a here string to create an LCM file using a Hyper-V VM and invoke-command.
                      If the here string starts with [ the file created is blank if viewing with get-content. Viewing the file with PSEdit, the file is full of squares.

                      Code used to generate this:

                      $lcmscript = @'
                      [DSCLocalConfigurationManager()]
                      configuration LCMPush
                      {
                      Node $AllNodes.Where{$_.Role -eq "Primary DC"}.Nodename
                      {
                      Settings
                      {
                      RebootNodeIfNeeded = $true
                      ActionAfterReboot = 'ContinueConfiguration'
                      ConfigurationMode = 'ApplyAndAutoCorrect'
                      CertificateID = "REPLACEWITHFRESHLYCREATEDTHUMBPRINT"
                      }
                      }
                      }

                      # Create the computer.meta.mof in folder
                      LCMPush -configurationData c:\dsc\dscconfigdata.psd1 `
                      -OutputPath c:\dsc\LCM
                      '@

                      Invoke-Command -VMName $vmname -Credential $cred -ScriptBlock { New-Item c:\dsc\lcm -ItemType…

                      1 vote
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        I agree to the terms of service
                        Signed in as (Sign out)

                        We’ll send you updates on this idea

                        5 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →

                        Interesting…I’m not able to repro it from a PowerShell 5.1 to 5.1 box. Could you paste the output of your $PSVersionTable?

                        Also, I’m assuming you’ve saved the script that includes the here string somewhere? Could you paste the output of Format-Hex .\hereString.ps1 | Select-Object -First 1? Even better, could you paste the same thing on the resultant output (i.e. Format-Hex C:\dsc\lcm\dsclcm.ps1 | Select-Object -First 1)?

                      • Convertfrom-json & Foreach-Object Operation vs ScriptBlock statement returns different output

                        Beginning in Windows PowerShell 3.0, there are two different ways to construct a ForEach-Object command. - Yes and no.

                        PS > $p
                        [
                        {
                        "Name": "aaCenter",
                        "Id": 4256
                        },
                        {
                        "Name": "AiNap",
                        "Id": 3408
                        },
                        {
                        "Name": "AllShareDMS",
                        "Id": 5044
                        }
                        ]

                        # Blank result
                        $p | ConvertFrom-Json | % Name

                        #ScriptBlock or invoke GetEnumerator() method works as expected
                        PS > ($p | ConvertFrom-Json).GetEnumerator() | % Name
                        aaCenter
                        AiNap
                        AllShareDMS

                        PS > $p | ConvertFrom-Json | % {$_.Name}
                        aaCenter
                        AiNap
                        AllShareDMS

                        PS > ($p | ConvertFrom-Json).foreach{$_.Name}
                        aaCenter
                        AiNap
                        AllShareDMS

                        # Object doesn't contain a property Name
                        PS > $p |…

                        1 vote
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          I agree to the terms of service
                          Signed in as (Sign out)

                          We’ll send you updates on this idea

                          0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                        • -certificate parameter needed on the Install-Module cmdlet

                          I have built an internal Powershell Gallery where all uploaded (Powershell related) items are signed but I am in an 'Allsigned' environment mandated from 'on high' that cannot be changed which means that every time someone uses the 'Install-Module' cmdlet at the moment, unless they're installing something directly from my, self-managed, internal Gallery, whatever they've decided to install and download can't work unless they go find it and sign it as a seperate step. It would present less of a barrier to adoption to people if the downloading of a module from a repository allowed them to run the downloaded…

                          1 vote
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            I agree to the terms of service
                            Signed in as (Sign out)

                            We’ll send you updates on this idea

                            0 comments  ·  Package Management  ·  Flag idea as inappropriate…  ·  Admin →
                          • WMF: It's annoying to not have an independent setup for Win10

                            Hello

                            It is really annying that Microsoft still patronizes their Customers and don't allow to setup WMF (e.g. Version 5.1) on Windows 10 without Windows Update / without upgrading to the anniversary release.

                            We have 650 Desktops and we have not yet finished all compatibility tests, but we have Developers which needs WMF 5.1.

                            Please, keep in mind simple, friendly installations and not microsoft internal political decisions.

                            Because there are many Operating Systems with open source package managers, you could peek how they are solving such problems. Since decades.

                            Kind regards, Thomas

                            3 votes
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              I agree to the terms of service
                              Signed in as (Sign out)

                              We’ll send you updates on this idea

                              1 comment  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
                            • Test-Connection timetolive parameter should be renamed to HopLimit

                              TimeToLive is a misnover for HopLimit. Though this has been corrected in the IPv6 rfc, Test-Connection still references this parameter as TimeToLive, which leads to confuse it with a timeout.

                              5 votes
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                I agree to the terms of service
                                Signed in as (Sign out)

                                We’ll send you updates on this idea

                                1 comment  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
                              • New-CimSession from within a PSJob created by a scheduled task

                                I'm having a strange issue with one of my scripts, where the New-CimSession cmdlet throws out a strange error when the script is run as a scheduled task, but not when I run it interactively under the same user account.

                                The details are described here:
                                https://github.com/PowerShell/PowerShell/issues/3538

                                1 vote
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  I agree to the terms of service
                                  Signed in as (Sign out)

                                  We’ll send you updates on this idea

                                  0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                                • Roaming PowerShell profile using OneDrive

                                  Most IT pros use multiple computers but can't have a consistent PowerShell experience across computers due to different versions of PS Profile. Keeping a single version of the profile updated and synchronized across computers adds management overhead.

                                  Solution:
                                  - Make the profile roaming using OneDrive. The following post shows how to synchronize the profile using OneDrive, but having this option out of the box would help.

                                  Nice to have:
                                  - Allow the user to choose default location for the PowerShell profile

                                  Synchronize your PowerShell Profile with OneDrive
                                  http://wp.me/p2C5zw-19K

                                  2 votes
                                  Sign in
                                  Check!
                                  (thinking…)
                                  Reset
                                  or sign in with
                                  • facebook
                                  • google
                                    Password icon
                                    I agree to the terms of service
                                    Signed in as (Sign out)

                                    We’ll send you updates on this idea

                                    0 comments  ·  ISE and tooling  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Curated Module Lists

                                    The PowerShell gallery should allow users to create "lists" of modules (think of it as an Amazon wish list).

                                    A user could create a "favorites" list and add modules and scripts to it to keep track of their favorites over time (maybe even "subscribe" to notifications of new releases of things on the list).

                                    A user could also create a "user management modules" list or a "stretching PowerShell's limits" list or a "should have been in the box" list, or a "things I use in my prompt" list ...

                                    But most importantly, users should be able to SHARE those lists,…

                                    13 votes
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      I agree to the terms of service
                                      Signed in as (Sign out)

                                      We’ll send you updates on this idea

                                      survey  ·  0 comments  ·  PowerShell Gallery  ·  Flag idea as inappropriate…  ·  Admin →
                                    • 6 votes
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        I agree to the terms of service
                                        Signed in as (Sign out)

                                        We’ll send you updates on this idea

                                        1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →

                                        Would be interested in understanding the scenario where you are using the cmdlet & specifying the reason for rebooting. To explain: our previous assumption was that users would EITHER use the server UI that captured this information, OR use the cmdlet (often so they didn’t need to supply that reason text).
                                        So, what would help is to understand in what situations the cmdlet is being used and specifying the reboot explanation is desirable.

                                      • aliases should be able to contain parameters

                                        While PowerShell's introduction of aliases to Windows command lines is a (long due) help, they are very limited. Compared to aliases found in Linux shells such as bash, aliases in PowerShell have one glaring weakness: they can only replace a single token with another single token.

                                        For example, on Linux, I can do the following:
                                        # Add default parameters to ls so it shows hidden files and uses color
                                        alias ls='ls -A --color=auto'
                                        # Add an alias that shows ls long-form output and file type indicators
                                        alias ll="ls -lF"

                                        On Po9werShell, I can't do anything like that. "ls" is aliased…

                                        1 vote
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          I agree to the terms of service
                                          Signed in as (Sign out)

                                          We’ll send you updates on this idea

                                          1 comment  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                                        • Gallery help site needs new capability

                                          The documentation site need a menu or link item to quickly switch versions of a help topic. Like the old MSDN site.

                                          Example Site topic: https://msdn.microsoft.com/powershell/reference/5.1/Microsoft.PowerShell.Utility/Read-Host

                                          The version access is important for support issues to be able to quickly switch versions as the "-online" with help always targets the current version or nothing.

                                          1 vote
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            I agree to the terms of service
                                            Signed in as (Sign out)

                                            We’ll send you updates on this idea

                                            1 comment  ·  Documentation  ·  Flag idea as inappropriate…  ·  Admin →
                                          • Don't see your idea?

                                          Feedback and Knowledge Base