Page 1 of 1

[02 Jan 2009] GetWeekday

Posted: Sat Jun 13, 2020 5:32 pm
by GMKai
Note: This is an archived post that was originally sent to the Hollywood mailing list on 02 Jan 2009 18:42:50 +0000

Hello,

as of now "GetWeekday() returns the Daystring of the current day e.g. Friday.

1. Would it be possible to change the function to accept a given date as a paremeter?

2. As the result is string depending on the usersetting would it be possible to return a number from 1 - 7 for each weekday?

Thank you and kind regards Kai

[09 Jan 2009] Re: GetWeekday

Posted: Sat Jun 13, 2020 5:32 pm
by airsoftsoftwair
Note: This is an archived post that was originally sent to the Hollywood mailing list on Fri, 09 Jan 2009 01:09:03 +0100
Hello,

as of now "GetWeekday() returns the Daystring of the current day e.g. Friday.

1. Would it be possible to change the function to accept a given date as a paremeter? 2. As the result is string depending on the usersetting would it be possible to return a number from 1 - 7 for each weekday?
Hmm, not likely. But you can easily implement this on your own. Calculating a weekday from a given date shouldn't be so difficult... I bet there are lots of example source codes for this stuff available via Google.

[11 Jan 2009] Re: GetWeekday

Posted: Sat Jun 13, 2020 5:32 pm
by lazi
Note: This is an archived post that was originally sent to the Hollywood mailing list on Sun, 11 Jan 2009 14:58:40 +0100

On Aminet there is a date.library and it has a very good guide about the different date systems AFAIR.

http://aminet.net/package/util/libs/DateLib