C#: Json – Populate objects from a file

Please see my other C# articles.

Reading data from a file into objects

In this article I’ll demonstrate how to use Json to read a file’s contents and populate a list of objects with that data.

First, I’ll create a method which uses reads data from a Json file into a string, which Json then uses to uses to convert into a list of objects.

Note: Deserialization means to convert strings into objects.

Now, I’ll call my method to read data from a Json file.