S
Steven8579
Guest
Good afternoon,
I'm trying to get the time formatted in hh:mm tt format. For example 02:30 PM. I have a database called SubJobs, a datagridvew called datagridvew1 and a column in SubJobs called Time which is a Time(7) datatype.
This is the query I tried:
string query2 = "select chName, MassType, Date, Time, Stipend from SubList where chID= '" + Person.churchID.ToString() + "'; ";
This is the code I tried to format the column in DataGridView:
dataGridView1.Columns[3].DefaultCellStyle.Format = "hh:mm tt";
When I execute the code I get the following message:

Any help would be greatly appreciated!
Thanks,
Steven
Continue reading...
I'm trying to get the time formatted in hh:mm tt format. For example 02:30 PM. I have a database called SubJobs, a datagridvew called datagridvew1 and a column in SubJobs called Time which is a Time(7) datatype.
This is the query I tried:
string query2 = "select chName, MassType, Date, Time, Stipend from SubList where chID= '" + Person.churchID.ToString() + "'; ";
This is the code I tried to format the column in DataGridView:
dataGridView1.Columns[3].DefaultCellStyle.Format = "hh:mm tt";
When I execute the code I get the following message:

Any help would be greatly appreciated!
Thanks,
Steven
Continue reading...