Hi,
Say I have an interface like this:
public interface ISomeInterface
{
...
}
I also have a couple of classes implementing this interface;
public class SomeClass : ISomeInterface
{
...
}
Now I have a WPF ListBox listing items of ISomeInterface, using a custom DataTemplate.
The databinding engine will apparently not (that I have been able to figure out) allow me to bind to interface properties - it sees that the object is a SomeClass object, and data only shows up if SomeClass should happen to have the bound property available as a non-interface property.
How can I tell the DataTemplate to act as if every object is an ISomeInterface, and not a SomeClass etc.?
Thanks!