In Visual Studio, is there a way to automatically convert object data into object creation code?


In Visual Studio or in a VS plugin, is there a way to automatically convert an objects data at run time to generated class initialization code? I am trying to create test data and It would be really convenient to have the ability to copy a run time objects data into object initialization code through intellisense.

If this isn't possible or has yet to be created, are there alternatives to accomplish something similar?

Assuming you're talking about C++ - this is called copy constructor and it's part of the language definition.