class Base {} class Concrete : Base {} class Normal { public Concrete ConcreteProp { get; set; } }
Base prop = new Concrete(); Normal obj = new Normal(); obj.ConcreteProp = prop;
Edited to add: OK, so I butchered the problem description in my haste. Mea culpa. I think I just stumbled into one of my own pet peeves. Here's the actual code that doesn't work in case you're interested:
System.Data.Common.DbDataAdapter adapter = sqlDataAdapter1; System.Data.SqlClient.SqlCommandBuilder cb = new System.Data.SqlClient.SqlCommandBuilder(); cb.DataAdapter = adapter;
Disclaimer The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.