I am passing a collection of an Interface type as the datasource for a the Grid and when I try to render the page I get thr following error...
Unhandled exception rendering component: Cannot create an instance of an interface.
System.MissingMethodException: Cannot create an instance of an interface.
at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean wrapExceptions, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& hasNoDefaultCtor)
at System.RuntimeType.CreateInstanceDefaultCtorSlow(Boolean publicOnly, Boolean wrapExceptions, Boolean fillCache)
at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, Boolean wrapExceptions)
at System.Activator.CreateInstance[T]()
at Telerik.Blazor.Components.Grid.GridFilterHeaderBase`1.get_PropType()
I do not know the datasource actual concrete type until run time. Is there a way to work around this?
Thanks,
Jeff