首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > CSS >

请问关于VBS的异常

2012-03-07 
请教关于VBS的错误.各位帮忙看下错误在哪呢?错误提示信息是:行:106字符:1错误:缺少 next-----------------

请教关于VBS的错误.
各位帮忙看下错误在哪呢?
错误提示信息是:
行:106
字符:1
错误:缺少 'next '
----------------------------------------
<html>

<head>
<title> 四季日历 </title>
</head>

<BLOCKQUOTE>
<SCRIPT   language=vbs>
<!--
documnet.open
call   displaycalender()
doucment.close
'定义所需变量
'currentdate       表示当日在一周内所在的天,即几号
'currentday         表求当日在一周内所在的天,即星期几
'currentyear       表示当日所在年份
'currentmonth     表示当日所在月份
'xday                     关键变量,表求日历中,月份开始时到1号所空的天数
dim   currentdate,   currentday,currentyear,   currentmonth,   xday
'下面得到与当日有关的日期信息
sub   dayinfo
        date_info=date()
        currentdate=day(date_info)
        currentday=weekday(date_info)-1
        currentmonth=month(date_info)
        currentyear=year(date_info)
        tempday-currentdate   mod   7
        xday=(currentday+7-tempday)   mod   7   +1
end   sub
'下面的过程打印日历
sub   displaycalender

'定义数组,表示每月的天数
dim   alldays(11)
alldays(0)=31
alldays(1)=28
alldays(2)=31
alldays(3)=30
alldays(4)=31
alldays(5)=30
alldays(6)=31
alldays(7)=31
alldays(8)=30
alldays(9)=31
alldays(10)=30
alldays(11)=31

'定义数组,表示星期几的英文缩写
dim   weekdayname(6)
weekdayname(0)= "Su " '
weekdayname(1)= "Mon "
weekdayname(2)= "Tue "
weekdayname(3)= "Wed "
weekdayname(4)= "Thu "
weekdayname(5)= "Fri "
weekdayname(6)= "Sat "

dim   monthname(11)
monthname(0)= "Junuary "
monthname(1)= "Februany "
monthname(2)= "March "
monthname(3)= "April "
monthname(4)= "May "
monthname(5)= "June "
monthname(6)= "July "
monthname(7)= "August "
monthname(8)= "Sepetember "
monthname(9)= "October "
monthname(10)= "November "
monthname(11)= "December "

'调用过程dayinfo,得到日期信息,存入公共变量中
call   dayinfo

'测试闰年
if(currentyear   mod   4=0)   then   alldays(1)=alldays(1)+1

'利用writeln函数向日葵浏览器窗口写入HTML代码
'先写HTML的头部分
document.writeln( " <html> ")
document.writeln( " <head> ")
document.writeln( " <title> 四季日历 </title> ")
document.writeln( " </head> ")
document.writeln( " <body> ")
'再写形成日历的表格,为了看清楚,在样式信息中定义了大字本
document.writeln( " <tabel   border=0   style   = 'font-size=32pt;text-align:center '> ")
'书写表格的标题
document.writeln( " <caption   style= 'color:blue '> ")
document.writeln(currentyear&monthname(currentmonth))
document.writeln( " </caption> ")
'书写表头,表头是星期几的英文名称
document.writeln( " <tr> ")
for   i=   0   to   6
        document.writeln( " <th   style= 'color:red ' "&weekdayname(i)& " </th> ")
next

document.writeln( " </tr> ")


'书写表体,循环次数为当月天数加上xday的天数
for   i=1   to   alldays(currentmonth)+xday
'如果写满了一周就换行
if(i   mod   7=1)then   document.writeln( " <tr> ")
'如果循环变量小于xday,   刚写出空的单元格
if(i <=xday)   then   document.writeln( " <td> </td> ")
'否则写入正式的日期
else
'如果循环至当日,则采用另一种特殊的样式表示
if(i=currentdate+xday)then
document.writeln( " <td   style= 'color:lime '> "&(i-xday)& " </td> ")
else
document.writeln( " <td> "&(i-xday)& " </td> ")
end   if
end   if
end   if
'写满一周就换行
if(i   mod   7=0)then   document.writeln( " </tr> ")
next

'书写表尾和文档尾部
document.writeln( " </tr> ")
document.writeln( " </table> ")
document.writeln( " </body> ")
document.writeln( " </html> ")
end   sub

-->
</SCRIPT>
</BLOCKQUOTE>
<body>

</body>

</html>


[解决办法]
写的太乱了

tempday-currentdate mod 7
什么意思?

documnet.open
-->

document.open

其它还有

热点排行