Thanks for replying,
I already get what I want...but I'm still want to make it more informative for user...
The code that I get now is just pop up the message tell the user earlier 3 days reach due date. But the problem is, it will pop up 2 times when the due date got 2 in the database. So, how can I make it pop only once and instead of doing that I need to make count on that. So, how can I make it count the date that reach due date.Below was the code for pop up message to user when reach due date.
- while (reader.Read())
-
{
-
string reportdate = reader.GetValue(3).ToString();
-
-
DateTime enddate = DateTime.Parse(reportdate);
-
if ((DateTime.Now - enddate).Days < 3)
-
{
-
//reportdate = System.Convert.ToInt32(cmd.ExecuteScalar());
-
MessageBox.Show("Almost reach due date on ");
-
}
-
-
}