I have a generic type Store and use Activator to make an instance of this type. Now how, after using the Activator, can I cast the resulte
Let's say that someObjectThatImplementsIStorable is of type MyStorable.
e.g. MyStorable someObjectThatImplementsIStorable = new MyStorable( ); ... // rest of your code here.
Then x cannot be cast to Store, but it can be cast to Store. The following will work: (Store)x
Note that although MyStorable implements IStorable, there is no relationship between Store and Store. These are two distinct classes that do not derive from each other.
u.