日期:2014-05-17 浏览次数:20823 次
private void touxiang_Load(object sender, EventArgs e)
{
this.CreateMyListView();
}
private void CreateMyListView()
{
ListView listView1 = new ListView();
listView1.Bounds = new Rectangle(new Point(10, 20), new Size(380, 330));
ListViewItem item1 = new ListViewItem("头像1", 0);
ListViewItem item2 = new ListViewItem("头像2", 1);
ListViewItem item3 = new ListViewItem("头像3", 2);
ListViewItem item4 = new ListViewItem("头像4", 3);
ListViewItem item5 = new ListViewItem("头像5", 4);
ListViewItem item6 = new ListViewItem("头像6", 5);
ListViewItem item7 = new ListViewItem("头像7", 6);
ListViewItem item8 = new ListViewItem("头像8", 7);
ListViewItem item9 = new ListViewItem("头像9", 8);
ListViewItem item10 = new ListViewItem("头像10", 9);
ListViewItem item11 = new ListViewItem("头像11", 10);
ListViewItem item12 = new ListViewItem("头像12", 11);
ListViewItem item13 = new ListViewItem("头像13", 12);
ListViewItem item14 = new ListViewItem("头像14", 13);
ListViewItem item15 = new ListViewItem("头像15", 14);
ListViewItem item16 = new ListViewItem("头像16", 15);
listView1.Items.AddRange(new ListViewItem[]
{
item1,
item2,
item3,
item4,
item5,
item6,