Ability to export object while debugging

I have been using Rider for about a month (maybe two) now and its a great product.  I'm getting better at it everyday.  However, I haven't been able to figure out is this functionality is possible.  In Visual Studio there was an extension called OzCode which has the ability to export the contents of a variable, while in debug mode, to either:

  • A C# object
  • A json structure
  • A XML object

Does Rider have this functionality that I'm maybe not finding? 

 

J

5
3 comments

Hi J! 

Rider does not support functionality from OzCode. However, we have a corresponding feature request for the described feature: RIDER-65817. Feel free to follow it and upvote to raise its priority. 

 

0

I use such approach from years to export variables while debugging:

  • Shft-F9 to Evaluate a variable, type it and validate that you are getting it right
  • wrap it with a JSON serializer, e.g.
    • Newtonsoft.Json.JsonConvert.SerializeObject(var_name)  or
    • System.Text.Json.JsonSerializer.Serialize(var_name)
  • paste it in your favorite text editor and format it - Npp, VSCode, etc.
  • eventually compare it with expected result with WinMerge or another diff tool.
5

Please sign in to leave a comment.