You shouldn't need to do this, violation of an interface (by downcasting) should only be done with great care and good reason.
There are two use cases you mentioned for wanting to do this, viewing and editing.
For viewing, the solution is simple. Either override .ToString()
to get the information you need, or if you need "pretty" output, create an interface function DrawInfo
to do this display for you (passing parameters as necessary, like an area of the screen to draw to).
For editing, you'll want a DrawDialog
function. Like the DrawInfo
function, this could take an "area" parameter. Assuming this dialog can manage its own UI controls (buttons and the like) you're done. This, by the way, would be analogous to having a class return a UserControl
in WPF/Winforms to do the same thing.
Having these in the interface ensures that every derived class has it (invoking a method via reflection is not safe or fun!) and you don't need to worry about the types at runtime, polymorphism takes care of everything for you.