Browse by Tags

Tagged Content List
  • Blog Post: PowerTip: Find DISM-Related PowerShell Cmdlets

    Summary : Learn how to find all Windows PowerShell cmdlets that work with DISM. How can I find all Windows PowerShell cmdlets that work with Deployment Image Servicing and Management (DISM)? Use the Get-Command cmdlet and specify the DISM module: Get-Command -Module dism
  • Blog Post: Weekend Scripter: Use PowerShell to Find Longest Cmdlet Name

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell to find the longest cmdlet name. Microsoft Scripting Guy, Ed Wilson, is here. This is an exciting time of the year, as we get ready for the PowerShell Summit in Charlotte and for the Microsoft Ignite conference in Chicago...
  • Blog Post: Don’t Script: Create PowerShell Snippets

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about creating custom Windows PowerShell snippets. Hey, Scripting Guy! Thank you for yesterday's blog post, Don’t Write Scripts: Use Snippets . I like the idea of having access to Windows PowerShell script snippets. But I used to create...
  • Blog Post: Don’t Script: Edit PowerShell Command History

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about editing the Windows PowerShell command history. Hey, Scripting Guy! I liked your ideas in Avoid Scripting: Use PowerShell Command History . My problem is that I seldom (if ever) type commands perfectly the first time—often, not even the...
  • Blog Post: Avoid Scripting: Use PowerShell Command History

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about avoiding Windows PowerShell scripting by using command history. Hey, Scripting Guy! I used to have a program that I could use to keep track of commands I typed at the command prompt. It permitted me to use macros to replay those commands or...
  • Blog Post: Write and Run PowerShell Script Without Scripting

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about writing and running a Windows PowerShell script without scripting. Hey, Scripting Guy! I like using the Windows PowerShell ISE, but I do not have rights to run a script. I am stuck using a twenty year-old command prompt with Windows PowerShell...
  • Blog Post: Weekend Scripter: Fun Things to Do with PowerShell

    Summary : Windows PowerShell MVP, Teresa Wilson, talks about fun things to do with Windows PowerShell. Microsoft Scripting Guy, Ed Wilson, is here. Today we have a guest blog post from Microsoft Honorary Scripting Guy and Windows PowerShell MVP, Teresa Wilson, who shares some fun things to do with...
  • Blog Post: Weekend Scripter: Control Processes with PowerShell

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell to control processes. Microsoft Scripting Guy, Ed Wilson, is here. This morning I am made a pot of Masala Chai. I found a pretty good recipe when I was doing a Bing search: Indian Masala Chai . One of my pet peeves...
  • Blog Post: Use PowerShell to View and Filter Information

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell to view and filter information. Hey, Scripting Guy! I am not a scripter—never have been, never will be. But over the years I have used lots of people's scripts to do different things. I actually got some of...
  • Blog Post: Don’t Learn PowerShell: Reaching Out

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about running commands on remote servers. Hey, Scripting Guy! One of the things I really don’t understand is why Windows PowerShell is broken. I look at commands like you suggest, but they don’t work. Specifically, I wanted to see the...
  • Blog Post: Don’t Learn PowerShell: Use Cmdlets

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell cmdlets to do IT ops work. Hey, Scripting Guy! I have been an IT pro for many years, and to be honest, I am really good at my job. Now it seems you guys are abandoning me. I have been a loyal Microsoft supporter for...
  • Blog Post: PowerTip: Automatically Find Options in PowerShell

    Summary : Learn how to see available options in the Windows PowerShell ISE. How can I easily see what options are available when I type in a cmdlet name in the Windows PowerShell ISE? Use IntelliSense. There are two ways to display IntelliSense: 1. From the Edit menu, select Start Intellisense...
  • Blog Post: Predict the Future with PowerShell

    Summary : Microsoft Scripting Guy, Ed Wilson, discusses using Windows PowerShell to see what a command will do before it does it. Hey, Scripting Guy! My football coach always said, “If you’re scared, admit you’re scared.” Well, Scripting Guy, in honor of my old coach, I am...
  • Blog Post: Don’t Learn PowerShell, Use PowerShell

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about getting started with Windows PowerShell. Hey, Scripting Guy! I get it. I need to learn Windows PowerShell—I see it mentioned everywhere. The problem is that I don’t have five years to learn the stuff. And besides that, by the time...
  • Blog Post: PowerTip: Find PowerShell Commands

    Summary : Learn how to easily find Windows PowerShell commands. How can I use Windows PowerShell if I do not know the appropriate command to use or the available options? In the Windows PowerShell console, type Show-Command . In the dialog box that appears, type what you need— such as process...
  • Blog Post: PowerTip: Use PowerShell to Round to Specific Decimal Place

    Summary : Use Windows PowerShell to round numbers to a specific decimal place. How can I use Windows PowerShell to round a number to a specific number of decimal places, and continue to have a number instead of converting it to a string. Use the Round static method from the System.Math class. By...
  • Blog Post: Rounding Numbers—PowerShell Style

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell to round numbers. Hey, Scripting Guy! I think your series about formatting numbers has been pretty interesting. However, everything you have shown has a major problem—and that is that you convert numbers into...
  • Blog Post: PowerTip: Round a Number with PowerShell

    Summary : Use Windows PowerShell to round numbers to a specific decimal place. How can I use Windows PowerShell to round a number to a specific number of decimal places, and continue to have a number instead of converting it to a string. Use the Round static method from the System.Math class. By...
  • Blog Post: PowerTip: Express Percentage in PowerShell

    Summary : Learn an easy method to express a percentage in Windows PowerShell. How can I use Windows PowerShell to express a two-decimal place percentage? For example, I have multiple calculations in a Windows PowerShell script, and I am tired of always dividing two numbers, multiplying by a hundred...
  • Blog Post: Using PowerShell and Standard Number Formats

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using standard number formats. Hey, Scripting Guy! I love using Windows PowerShell. I use it for everything. My problem is that it does not do everything automatically. For example, I use the Get-Volume cmdlet a lot to check on disk space,...
  • Blog Post: Formatting PowerShell Decimal Places

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about using strings to format the display of decimal places in Windows PowerShell. Hey, Scripting Guy! One of the things I have a problem with is when I get numbers that have a lot of decimal places. I mean, how do I really get rid of them—at...
  • Blog Post: PowerTip: Format Decimal Numbers in PowerShell

    Summary : Learn how to display a specific number of decimal points in Windows PowerShell. How can I use Windows PowerShell to display only one decimal place on a number that currently has two? Use a custom number format string with the ToString method from the number, for example: PS C:\>...
  • Blog Post: Working with Fixed Number Sizes in PowerShell

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about working with fixed number sizes in Windows PowerShell. Hey, Scripting Guy! I have a script that returns a specific type of number, so I added a type constraint on the variable that holds the number. The problem is that sometimes when I run...
  • Blog Post: PowerTip: Use Parentheses to Override Operator Precedence

    Summary : Use parentheses to override operator precedence in Windows PowerShell. How can I ensure that a math expression that keeps returning incorrect information will work properly in Windows PowerShell? In Windows PowerShell (as in other languages), math operators have a precedence. Therefore...
  • Blog Post: Understanding Numbers in PowerShell

    Summary : Microsoft Scripting Guy, Ed Wilson, talks about numbers in Windows PowerShell. Hey, Scripting Guy! One of the things that is frustrating to me with Windows PowerShell is the way that it handles numbers. For example, I want to know the percent of processor utilization for something, and it...