Tags » Powershell-basics

Creating JSON from a hash table

A question on the forum was asking about creating a JSON structure for use with a REST API.

The original has table looked like this… 512 more words

Powershell Basics

Passing data into Jobs

PowerShell jobs are a powerful tool fro running processes in the background. You have to remember that a PowerShell job runs in a separate process that only exists for the duration of the job. 258 more words

Powershell Basics

Masking output

A question on the forum on how to stop the output from New-Item raises an important point. Many cmdlets produce output when run for example… 204 more words

Powershell Basics

Scripting Games July 12015 thoughts on the solution

The July 2015 puzzle can be found here:


Write a one-liner that produces the following output (note that property values will be different from computer to computer; that’s fine). 755 more words

Powershell Basics

Using parameters instead of read-host when getting AD replication data

I’ve seen a lot of scripts recently that use Read-Host to get input data. This is generally not best practice – I tend to only use Read-Host if I want to get a password and obscure the text on screen. 159 more words

PowerShell And Active Directory

Data for comparisons

A question on the forum asked about storing data used in comparisons, The example was based on a list if IP addresses where some were known to be good and the questioner wanted to filter out the known good ones so he just had to investigate the rest. 161 more words

Powershell Basics

Input validation on multiple regex

One of the things I like about writing advanced functions is the ability to validate the input. if you test the input immediately you can often stop mistakes being made. 763 more words

Powershell Basics