The type {0} may not be used in this context. To use {0} as a parameter, return type, or member of a class or struct, the ...

The type {0} may not be used in this context. To use {0} as a parameter, return type, or member of a class or struct, the parameter, return type, or member must be declared as type {0} (it cannot be object). Objects of type {0} may not be used in un-typed collections, such as ArrayLists.