none
How to retrieve full information RRS feed

  • السؤال

  • Hello,

    Certainly very basic question but…. How can I retrieve and display full information of launched commands. Not easy to explain so look at the following example Screenshot :-)

    How can I "remove" the three dots and replace them with all the commands at the end of the column ExportedCommands ?

    Thanks in advance

    14/ذو القعدة/1440 10:13 ص

الإجابات

  • Not sure f it will help or not but try below:

     Get-Module Microsoft.PowerShell.Management | Select ModuleType, Version, Name, @{n="ExportedCommands"; e = { [string]$_.ExportedCommands.keys }} | ft -Wrap


    • تم التحرير بواسطة DumbleD0re 14/ذو القعدة/1440 01:00 م
    • تم وضع علامة كإجابة بواسطة Thierry BRUNI 14/ذو القعدة/1440 01:06 م
    14/ذو القعدة/1440 12:53 م

جميع الردود

  • Hi Thierry,

    I'm Thinking you don't use the appropriate cmdlet. Choose this one :

    Get-Command -Module Microsoft.PowerShell.Management

    It returns all cmdlets of the module.

    you can also search like this :

    Get-Command -Name get-* Get-Command -Verb get Get-Command -Noun *WMI

    Regards

    Olivier

    14/ذو القعدة/1440 11:05 ص
  • Get-Module Microsoft.PowerShell.Management | Format-List

    This is why you need to take time to learn PowerShell instead of guessing how to use it.  The answer is something you would have learned in the first couple of chapters of any good book on PowerShell.

    To get rid of the dots make your console wider.  The output will not fit on your window so PS adds dots to show you it has cut off some of the output.

    If you just want the commands you can use "Get-Comamnd" or just ex[and the results.

    Get-Module Microsoft.PowerShell.Management | Select -Expand ExportedCommands


    \_(ツ)_/


    • تم التحرير بواسطة jrv 14/ذو القعدة/1440 11:11 ص
    • تم الاقتراح كإجابة بواسطة DumbleD0re 14/ذو القعدة/1440 11:24 ص
    14/ذو القعدة/1440 11:10 ص
  • Hello Olivier,

    Thanks for your answer. You provided me an other way to display this information and I am thankful for this, but what I am looking for is really to "expand" the line and have the same display of information.

    14/ذو القعدة/1440 12:16 م
  • Hello Dumbledore,

    Thanks for your answer. As you can see on the Following Screenshot my console is wider than the displayed result.

    The commandlet Select-Object with the Expand property only show me the the Exportedcommands column in a column display. But I will dig in with this hint.

    14/ذو القعدة/1440 12:38 م
  • Not sure f it will help or not but try below:

     Get-Module Microsoft.PowerShell.Management | Select ModuleType, Version, Name, @{n="ExportedCommands"; e = { [string]$_.ExportedCommands.keys }} | ft -Wrap


    • تم التحرير بواسطة DumbleD0re 14/ذو القعدة/1440 01:00 م
    • تم وضع علامة كإجابة بواسطة Thierry BRUNI 14/ذو القعدة/1440 01:06 م
    14/ذو القعدة/1440 12:53 م
  • Hey Dumbledore,

    Yes it helps a lot. It is exactly what I was struggling to achieve.  (expect the "MouleType"  ;-)  )

    Thanks a lot

    14/ذو القعدة/1440 01:06 م