Home
Manage Your Code
Snippet: Datetime selection (C#)
Title: Datetime selection Language: C#
Description: the first column the next 30 days in the year including the current day the second column is for description information. I didn't write this, i'm storing it here because of how useful it was for me Views: 121
Author: Wayne Burgess Date Added: 7/25/2008
Copy Code  
1            DateTime _date;
2
3            int n = 0;
4            int max = 30;
5
6            while (n < max)
7            {
8                _date = DateTime.Now.AddDays(n);
9                //listView1.Items.AddRange(

10                ListViewItem item = new ListViewItem(_date.ToShortDateString());
11                item.SubItems.Add("Description " + n);
12                listevent.Items.Add(item);
13
14                n++;
Usage
Put it in the List view load 
Notes
Created By Hawkstalon