论坛: 编程破解 标题: vbscript中的问题。 复制本贴地址    
作者: ljsh012 [ljsh012]    论坛用户   登录
做网页时,想在状态栏上显示时间和welcome to my homepage 的文字。显示时间的程序为
<script language=vbscript〉
sub change()
status=time()
settimeout "change()",1000
end sub

sub window_onload()
change
end sub
怎样把welcome to my homepage 的字样加进去。
谢谢!!

地主 发表时间: 04-03-08 00:18

回复: 286 [unique]   版主   登录
<script language=vbscript>
sub change()
status=CStr(time())+"  Welcome to my homepage." 
settimeout "change()",1000
end sub

sub window_onload()
change
end sub
</script>

B1层 发表时间: 04-03-08 09:16

回复: ljsh012 [ljsh012]   论坛用户   登录
能告诉我cstr()的作用吗,它是什么函数?

B2层 发表时间: 04-03-08 13:06

回复: ghame [ghame]   论坛用户   登录
dim a,b
b=cstr(a)
以上表达式的意思是将 a 转换成字符格式然后赋给 b
其中cstr中的c 代表“convert”,转换
str代表“string”,字符串。


[此贴被 ghame(ghame) 在 03月08日13时20分 编辑过]

B3层 发表时间: 04-03-08 13:18

回复: ljsh012 [ljsh012]   论坛用户   登录
很好,谢谢大家了。

B4层 发表时间: 04-03-08 19:25

论坛: 编程破解

20CN网络安全小组版权所有
Copyright © 2000-2010 20CN Security Group. All Rights Reserved.
论坛程序编写:NetDemon

粤ICP备05087286号