We've all been there: We start to work on a file that we think is available, only to find out that it's already opened and in use, meaning we have to wait until whatever process currently using the file has released its lock on it.
You may not think too often about how text is displayed in your PowerShell console, but under the covers, there's quite a bit going on.
- By Adam Bertram
- 06/13/2018
If PowerShell isn't already your go-to tool for reviewing your NIC configuration, it should be.
Here's how to automate building a document in Microsoft Word. Clippy not required.
Making code adaptable is a key skill for any coder. Here's a primer on how to stretch function parameters to fit a variety of situations.
- By Adam Bertram
- 05/16/2018
Replace your legacy ipconfig switches with these cmdlets in the DNSClient module.
Sometimes using ValidateSet isn't enough -- for instance, when you have multiple functions with the same parameter that you need to perform a task on.
- By Adam Bertram
- 05/03/2018
Here's how to make your data more useful -- or even just more presentable -- using the Join and Split operators and the Split method.
Synchronous code execution is fine for small scripts, but for more time-consuming scripts, consider running your code in the background as a job. Here's how.
- By Adam Bertram
- 04/18/2018
For those times when converting Excel files to .CSV just doesn't make sense.
Using these three commands, PowerShell allows you to read and manipulate just about every aspect of your command history.
- By Adam Bertram
- 03/29/2018
If you want to group parts of your code for debugging purposes or simple readability, the PowerShell ISE has the answer.
The next time you need to wait on a step in your script, don't just add a delay. Instead, use a Wait-Action function to wait just the right amount of time.
- By Adam Bertram
- 03/16/2018
Boe shows you how to write scripts using the built-in voices on your computer. Just make sure you've got your headphones on.
Changing network adapter properties can be a chore the more machines you have, and the more numbers you have to punch in. Script out the process, instead.
- By Adam Bertram
- 02/28/2018
From validating IP addresses to phone numbers, these are some of the handiest expressions in Boe's PowerShell toolbox. What are yours?
Using Azure Automation DSC gives administrators the same benefits of PowerShell DSC, but with some bonus tooling.
- By Adam Bertram
- 02/14/2018
The PerfMon tool has a lot troubleshooting advantages going for it, but its interface isn't necessarily one of them. Here's an alternative.
It's important to start tests with a clean session, especially when writing unit tests and creating mocks. Here's how to run Pester tests in a completely new PowerShell process.
- By Adam Bertram
- 02/01/2018
Using Windows Management Instrumentation makes it easy to pull information about the drives on your system or remote systems. Here's how.