I\'ve pored through the docs, StackOverflow, etc., can\'t seem to find this...
What I want to do is serialize/deserialize a simple value-type of object as a value, n
public class IPAddress
{
byte[] bytes;
public override string ToString() {... etc.
}
IPAddress ip = new IPAddress("192.168.1.2");
var obj = new () {ipValue = ip.ToString()};
string json = JsonConverter.SerializeObject(obj);
You are serializing the whole IP address instance. Maybe just try to serialize the address as a string. (This presumes that you have implemented the ToString-method.)