This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

how can i get the day of the week and month

Hi again

How can i give a month\day and let´s say i what to returnthe mont\day (60 days later) and if it is on a synday it will go to monday .. can someone help Or where is there a rutine for this

I have looked everywere and every page and cannot find an answer. I wonder is it possible

Thank you again

QZ

what do I do

Parents
  • I think the easiest method is to use time_t -- the number of seconds since some epoch (I think typically Jan 1, 1970, but I use January 1, 2000). To move out 60 days, just add the number of seconds in 60 days. Then convert the time stamp to its date & time components.

    To determine the day of the week, look into the Doomsday Date algorithm -- it takes the day, month, and year, and gives you the day of the week.

Reply
  • I think the easiest method is to use time_t -- the number of seconds since some epoch (I think typically Jan 1, 1970, but I use January 1, 2000). To move out 60 days, just add the number of seconds in 60 days. Then convert the time stamp to its date & time components.

    To determine the day of the week, look into the Doomsday Date algorithm -- it takes the day, month, and year, and gives you the day of the week.

Children
No data