ObjectListView不显示

时间:2013-05-14 04:53:28

标签: c# winforms

我正在尝试使用ObjectListView,但是在应该非常简单的事情上失败了。这是我的代码:

List<Book> books = new List<Book>();
Book book = new Book();
book.name = "book 1";
book.author = "author 1";
books.Add(book);
book = new Book();
book.name = "book 2";
book.author = "author 2";
books.Add(book);
this.objectListView1.SetObjects(books);

看起来很简单,编译好,但没有显示任何内容!

0 个答案:

没有答案