Contact Info

Crumbtrail

ActiveXperts.com » Administration » Powershell » Powershell 4.0 » ConvertTo-Json

ConvertTo-Json - Powershell 4.0 CmdLet

ActiveXperts Network Monitor ships with integrated Powershell scripts to monitor complex network. The scripts run out of the box
Download the ActiveXperts Network Monitor FREE version now »

ConvertTo-Json

Short description
Converts an object to a JSON-formatted string

Syntax


Description
The ConvertTo-Json cmdlet converts any object to a string in JavaScript Object Notation (JSON) format. The properties 
are converted to field names, the field values are converted to property values, and the methods are removed.


You can then use the ConvertFrom-Json cmdlet to convert a JSON-formatted string to a JSON object, which is easily 
managed in Windows PowerShell.


Many web sites use JSON instead of XML to serialize data for communication between servers and web-based apps.


This cmdlet is introduced in Windows PowerShell 3.0.