I have an interface with:
IList<int> CategoryIDs {get;set;}
Then a class that inherits this interface:
public IList<int> CategoryIDs
{
get {} // this part works
set { _categoryIDs = value; // error!
}
The set part of the accessor reports an error:
cannot implicity convert type
IList<int>toList<int>.
What should I do? confused.
You can instantiate and assign a List just fine with a minor tweak: