Skip to main content

You can actually use a JavaScriptConverter to accomplish this with the built-in JavaScriptSerializer. By converting your enum to a Uri you can encode it as a string.

I've described how to do this for dates but it can be used for enums as well.

   http://blog.calyptusCustom DateTime JSON Format for .eu/seb/2011/12/custom-datetime-json-serialization/NET JavaScriptSerializer.

You can actually use a JavaScriptConverter to accomplish this with the built-in JavaScriptSerializer. By converting your enum to a Uri you can encode it as a string.

I've described how to do this for dates but it can be used for enums as well.

 http://blog.calyptus.eu/seb/2011/12/custom-datetime-json-serialization/

You can actually use a JavaScriptConverter to accomplish this with the built-in JavaScriptSerializer. By converting your enum to a Uri you can encode it as a string.

I've described how to do this for dates but it can be used for enums as well.  Custom DateTime JSON Format for .NET JavaScriptSerializer.

Source Link

You can actually use a JavaScriptConverter to accomplish this with the built-in JavaScriptSerializer. By converting your enum to a Uri you can encode it as a string.

I've described how to do this for dates but it can be used for enums as well.

http://blog.calyptus.eu/seb/2011/12/custom-datetime-json-serialization/