前几天我问过,今天写出来了!!
function calculateweekno(begindate,enddate,inputdate)
dim wdate(500,8)
z=0
x=0
strlong=len(cstr(inputdate))-9
inputdate=cdate(left(cstr(inputdate),strlong))
for i=cdate(begindate) to cdate(enddate)
if inputdate=i then
x=z
exit for
end if
if weekday(i)=7 then
z=z+1
end if
next
calculateweekno=x
end function
