public static void Main()
DataTable table = GetTable();
foreach (DataRow row in table.Rows)
Console.WriteLine("--- Row ---");
foreach (var item in row.ItemArray)
static DataTable GetTable()
DataTable table = new DataTable();
table.Columns.Add("Dosage", typeof(int));
table.Columns.Add("Drug", typeof(string));
table.Columns.Add("Patient", typeof(string));
table.Columns.Add("Date", typeof(DateTime));
table.Rows.Add(15, "Abilify", "Jacob", DateTime.Now);
table.Rows.Add(40, "Accupril", "Emma", DateTime.Now);
table.Rows.Add(40, "Accutane", "Michael", DateTime.Now);
table.Rows.Add(20, "Aciphex", "Ethan", DateTime.Now);
table.Rows.Add(45, "Actos", "Emily", DateTime.Now);