您的位置:首页 > 移动开发

The current type is an interface and cannot be constructed. Are you missing a type mapping?

2017-10-16 15:55 1151 查看
错误:

The current type is an interface and cannot be constructed. Are you missing a type mapping?

原因:

在使用DI(dependency injection)依赖注入的时候,忘记注册了。

解决:

注册一下接口和方法

container.RegisterType
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐