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.
  • Hot ideas
  • Top ideas
  • New ideas
  • My feedback
  1. Stop-Transcript -ErrorAction doesn't work

    The ErrorAction parameter on Stop-transcript doesn't work.

    for instance with SilenlyContine:

    PS G:> Stop-Transcript -ErrorAction SilentlyContinue
    Stop-Transcript : An error occurred stopping transcription: The host is not currently transcribing.
    At line:1 char:1
    + Stop-Transcript -ErrorAction SilentlyContinue
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidOperation: (:) [Stop-Transcript], PSInvalidOperationException
    + FullyQualifiedErrorId : InvalidOperation,Microsoft.PowerShell.Commands.StopTranscriptCommand

    Or with stop:
    Script: Stop-Transcript -ErrorAction Stop; write-output "This message sould not be printed"
    Result: Stop-Transcript : An error occurred stopping transcription: The host is not currently transcribing.
    At home\Untitled4.ps1:1 char:1
    + Stop-Transcript -ErrorAction Stop
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidOperation: (:) [Stop-Transcript], PSInvalidOperationException
    + FullyQualifiedErrorId : InvalidOperation,Microsoft.PowerShell.Commands.StopTranscriptCommand

    This message sould…

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  2. OutVariable gets the output from the next command (select) in the pipeline

    When running something like:
    gsv -ov all | sort -ov sorted | select name -first 10 -ov first10

    I'd expect $all.Count to be equal to $sorted.Count, but $sorted.Count is 10 and contains the same objects as $first10.
    This is different than in older versions (tried with -ver 2, and the variables have the expected objects. e.g. $all.Count == $sorted.Count)

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  3. Get- and Remove-DnsServerResourceRecord deficiencies

    Get- and Remove-DnsServerResourceRecord have a couple of deficiencies:

    1) most cmdlets support piping from Get- to Remove-, this does not currently work properly with Remove-DnsServerResourceRecord...

    "The input object cannot be bound because it did not contain the information required to bind all mandatory parameters: ZoneName"

    So, the objects returned from Get-DnsServerResourceRecord should contain the ZoneName property.

    2) Remove-DnsServerResourceRecord does not respect -Confirm:$false, even when it's specified, it asks for confirmation every time.

    i.e. this will ask for confirmation 200 times if you have 200 records (and -ZoneName must be specified because of the aforementioned issue!), at least thankfully you…

    2 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  4. Hardware Manufacturing Guides: Adding DISM cmdlets in PowerShell to complement guides & GitHub contribution

    Following the Manufacturing guides - the PowerShell DISM Module is still lacking several cmdlets for the remaining DISM command lines available in the command prompt.
    Is there a reason for not having them all there?
    I wanted to make some scripts for the module, but could only find the DSC xDISMFeature
    Is there a DISM Module GitHub repository?

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  5. [bug]: Get-ADUser -Filter {[attribute] -ne "ms"} filters out objects that return as null

    If you do a get-aduser -filter {company -ne "ms"}, the results filter out accounts that have no value for the company attribute defined. In my opinion this should not be the expected behavior; it should return all accounts, including the ones with a null company attribute, however it should not include results that have the company equal to "ms". The same behavior is also present with other attributes, such as "manager".

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  6. [BUG]New-PSDrive FileSystem does not work for Backup-SqlDatabase

    The -BackupFile parameter for the Backup-SqlDatabase cmdlet does not work properly with a drive created with the New-PSDrive cmdlet. It will first pull the default backup drive for the SQL Server then append the string for the file system. For example:

    New-PSDrive -Name "fs" -PSProvider FileSystem -Root "\MyFileServer\Backups"
    Backup-SqlDatabase -Database "MyDatabase" -ServerInstance "MySQLServer" -BackupFile "fs:\MyDatabase.bak"

    Would error with "Cannot find the path 'C:\BackupPath\fs:\MyDatabase.bak'"

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  7. When is Powershell v6 due to be released?

    When is Powershell v6 due to be released Will it work with Windows 10?

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  8. get-credential with a smart card

    I work in an environment that enforces 'smart card required' for all accounts admin or otherwise so I have multiple certificates on the smart card. I understand you can use a smart card with get-credential but the problem is it only has the first cert available when prompted. I need there to be a way to make all certs on the smart card available when prompted with get-credential. I'm also stuck using ActivClient so hopefully this isn't a limitation of the smart card provider.

    4 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  9. [Bug] Test-Path -PathType Containers Allows Users to Bypass Security Restrictions on Existence Testing

    Under PowerShell 5.1, the Test-Path command will return a [UnauthorizedAccessException] when you try to test a path the current user does not have access to. Normally this error is uncatchable, but it becomes so if you set the PathType to Container. Despite the name, Test-Path will verify the existence of both Containers and Leafs in this mode. Because the [UnauthorizedAccessException] error is ONLY returned for extant files and folders, a user can use it to confirm the existence of files and folders they should not be able to see or access.

    This one-liner allows you to bypass security restrictions:
    try{…

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  10. Unregister-ScheduledJob -Name 'Name' -WhatIf does not honor WhatIf

    Steps to reproduce

    Import-Module PSScheduledJob
    Register-ScheduledJob -Name 'test' -ScriptBlock {echo 'hello world'}
    Unregister-ScheduledJob -Name test -WhatIf
    Get-ScheduledJob

    Expected behavior

    I expect the job to still be there.

    It does work with Unregister-ScheduledJob -Id 11 -WhatIf.

    Actual behavior

    The scheduled job is corrupted.

    Get-ScheduledJob : Cannot get the test scheduled job because it is corrupted or in an irresolvable state. Because
    it cannot run, Windows PowerShell has deleted test and its results from the computer. To recreate the scheduled
    job, use the Register-ScheduledJob cmdlet. For more information about corrupted scheduled jobs, see
    aboutScheduledJobs_Troubleshooting.

    Environment data

    > $PSVersionTable
    Name Value

    2 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  11. Expand-Archive does not return a System.IO.FileInfo nor System.IO.DirectoryInfo

    The docs clearly say that Expand-Archive should return a System.IO.FileInfo or System.IO.DirectoryInfo but it has no output

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  12. Start-Transcript Does Not Capture Enter-PSSession

    Start-Transcript
    "local stuff"
    Enter-PSSession Server1
    "remote stuff"
    Exit-PSSession
    "more local stuff"
    Stop-Transcript

    Transcript does not show the remote stuff.

    5 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  13. Does sqlps need to be imported for PS vers 4.0

    In PS 3.0, it was known to have to do an Import-Module sqlps -DisableNameChecking command in order to get the SQL SMO CMDLETS for working with SQL Server. Is this still needed for PS 4.0? There doesn't seem to be any Documentation on this difference.

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  14. BUG: Import-Module does not autocomplete parameter switch "-Name"

    Typing "Import-Module -Na<tab>" does not autocomplete to "-Name", as if parameter switch "-Name" is no recognized.

    Other switches "-g<tab" and so forth work ok

    $PSVersionTable.PSVersion
    Major Minor Build Revision


    5 1 14393 953

    @arisaastamoinen

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  15. "update-help -module powershellget" errs apparently because helpinfoURI is called with https rather than http

    update-help : Failed to update Help for the module(s) :
    'PowerShellGet'
    The HelpInfoURI https://go.microsoft.com/fwlink/?LinkId=393271 does not start with HTTP.
    At line:1 char:1
    + update-help -module powershellget
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : NotSpecified: (HelpInfoUri:Uri) [Update-Help], Exception
    
    + FullyQualifiedErrorId : InvalidHelpInfoUriFormat,Microsoft.PowerShell.Commands.UpdateHelpCommand

    6 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  16. BUG: Set-Clipboard -AsHtml puts invalid CF_HTML on clipboard with non-ASCII text

    Repro with PowerShell 5.1.14986.1000:
    1) Set-Clipboard -AsHtml "abc"
    2) Paste into Word
    3) Text appears correctly as: abc
    4) Set-Clipboard -AsHtml "àbc"
    5) Paste into Word
    6) Text appears incorrectly as: ࢣ

    Appears CP 1251 text is being put in the CF_HTML, not UTF8.

    2 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  17. Get-Content bug: A parameter cannot be found that matches parameter name 'Encoding'

    Get-Conent with the Encoding parameter works against local file system paths such as this example:
    Get-Content -Encoding Byte -Path C:\Users\desktop.ini

    However, against a mapped network drive it does not:
    Get-Content -Encoding Byte -Path I:\Users\desktop.ini
    Get-Content : A parameter cannot be found that matches parameter name 'Encoding'.
    At line:1 char:13
    + Get-Content -Encoding Byte -Path I:\Users\desktop.ini

    The issue can be re-produced against a non-existing network drive as well.
    The behaviour is not expected and the error message is very misleading to users who don`t know what dynamic parameters is, since the same code works against a local path where -Encoding is…

    4 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  18. Property UserName and UserGroupName of Add-PswaAuthorizationRule command don't work

    OS : Windows Server 2016

    The command prompt an error when I add authorization rule in PowerShell Web Acces. It's syntax error : "domain/user".

    But, this is my commande :
    Add-PswaAuthorizationRule -ComputerName SRVDC01 -UserName 'FRPSUG\Test' -ConfigurationName Microsoft.PowerShell

    It's same issue with group, no quote, simple quote, double quote, local user...

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  19. Get-Service throws wrong exception if remote host is offline

    Get-Service returns exception as "Cannot find any service with service name" even if we give an offline/not existing host as argument for -ComputerName parameter

    4 votes
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  20. Register-ArgumentCompleter Should Support Module-Qualified Command Names

    Register-ArgumentCompleter does not appear to support module-qualified command names, such as:

    Register-ArgumentCompleter -CommandName Microsoft.PowerShell.Management\Get-Process

    Running this command does not return an error, but does not function either. Module-qualified command names are often considered a best practice so it would be helpful if this was supported. Thanks!

    1 vote
    Sign in
    (thinking…)
    Sign in with: Facebook Google
    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
  • Don't see your idea?

Feedback and Knowledge Base