How do I Serialize object to json using json.net which contains an image property

前端 未结 2 500
情深已故
情深已故 2021-01-03 06:17

I have an object with a number of public properties where one is of type image. I am trying to serialise this using json.net and assume that I will need to base64 encode th

2条回答
  •  梦谈多话
    2021-01-03 06:49

    I would recommend in this case to convert the image to base64 and then serialize it, here an example of how to do it in C#: Convert Image to Base64

提交回复
热议问题