使用IList / IEnumerable在MVC中创建列表 [英] Create List in MVC using IList / IEnumerable
本文介绍了使用IList / IEnumerable在MVC中创建列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你好,
我已经添加了一个参考我的MVC应用程序。(我已添加的参考是来自其他项目的BO模型)
现在,在我的Mvc应用程序中,我想根据dll文件中提供的Business Objects创建一个List。
我该怎么做!任何有关这方面的帮助都会受到很多赞赏!!
Hello,
I have added a Reference to my MVC Application.(The reference i''ve added is a BO Model from other Project)
Now, In my Mvc Application i would like to create a List based on the Business Objects that available in the dll file.
How can i do this!. Any help regarding this would be appreciated a lot!!
推荐答案
一些代码会帮助...
Anywayz ..
非常标准..
IEnumerable< boobject> objects = new List< boobject>();
objects.Add(CreateNewBOObject());
Some code would have helped ...
Anywayz ..
Its pretty standard ..
IEnumerable<boobject> objects = new List<boobject>();
objects.Add(CreateNewBOObject());
这篇关于使用IList / IEnumerable在MVC中创建列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文