How to serialize a c# list into a JArray RRS feed

  • Question

  • I created a list in c# example

    Dog dog = new Dog()

    dog.age = 3;

    dog.name = "terry"

    dog.pedigree = false

    List<Dog> lisdog = new List<Dog>();


    I want to convert that list into a JArray, can someone help?

    Monday, November 4, 2019 10:35 PM

All replies

  • What you want to do is to serialize (out) some JSON.

    I believe that JArray is a type that is not in .Net; it is in software that is not a Microsoft product. It is a type used for JSON by some other software.

    Sam Hobbs

    Tuesday, November 5, 2019 3:51 AM