访问问题:周数 [英] Access Question : Week Number
本文介绍了访问问题:周数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
任何人都可以提供帮助。需要计算一个日期的周数。但周必须在星期一而不是星期天开始。
Excel提供的功能
WeekNum(" Date",1)开始星期日星期一周
WeekNum(日期,2)在Moday开始一周
非常感谢
Zahed
Can anyone help. Need to calculate Week number of a date. But Week must start on a Monday not a Sunday.
Excel provides a function where
WeekNum("Date",1) starts week on Sunday
WeekNum("Date",2) starts week on Moday
many thanks
Zahed
推荐答案
查看工作日()
来自访问帮助:
WEEKDAY
根据代表日期的给定数字,返回1到7之间的数字,用于标识星期几。
语法
WEEKDAY(serial_number,return_type)
Serial_number是一个代表日期格式的日期或文本的数字,例如4-1- 1999"或者31-Oct-2000。
Return_type是一个数字:对于星期日= 1到星期六= 7,使用1;对于星期一= 1到星期日= 7,使用2;对于星期一= 0到星期日= 1,使用3。
Check out Weekday()
From access help:
WEEKDAY
Returns a number from 1 to 7 that identifies the day of the week, based on a given number that represents a date.
Syntax
WEEKDAY(serial_number,return_type)
Serial_number is a number that represents a date or text in date format, such as "4-1-1999" or "31-Oct-2000".
Return_type is a number: for Sunday = 1 through Saturday = 7, use 1; for Monday = 1 through Sunday = 7, use 2; for Monday = 0 through Sunday = 1, use 3.
将您的星期声明为数组:
Dim WeekNum(7)as String
然后为每个分配一个数字:
WeekNum(0)=" Monday"
WeekNum(1)=" Tuesday"
等。
Declare your week as an array:
Dim WeekNum(7) as String
Then assign a number to each:
WeekNum(0) = "Monday"
WeekNum(1) = "Tuesday"
etc.
问候语:
有关如何使用MS Excel Weeknum的任何提示请:>
$ b $b第一个工作日是星期六
$ b $b年限为52周
$ b $b指定用户的假日天数
>
感谢你的回复和帮助
谢谢你,祝你好运
COE201
Greeting:
Any hint please on how to use the MS Excel Weeknum such that:
First working day is Saturday
Years are 52 weeks
Specify holiday days by the user
Appreciations your reply and help
Thank you and Best regards
COE201
这篇关于访问问题:周数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文