I was wondering if there was a built in feature in .Net that could output (at runtime) all the properties and values in a given object and, if possible, even including sub-objects.
I’m thinking of Reflection or XML Serializion and saw some people mentioned JSON, but can’t really figure out how to do it the right way… Does anyone know if this is possibly a built in feature in .Net or if there’s a good example / tool that either already does this or could guide me in the right direction?
You could use the XmlSerializer class or take a look at the JSON.Net framework.