帮我解释ASP代码(从以下第6行开始)

来源:百度知道 编辑:UC知道 时间:2024/05/22 18:04:29
<script language="vbscript">
dim StrText,StrName,StrAdr,TyName
StrText="Hello World!"
StrName="Teacher!"
StrAdr="Beijing XiCheng Bicea!"
TyName=typename(StrText)
str1=left(StrText,6)
str2=mid(StrAdr,9,len(StrAdr))
str=str1 & StrName & str2
alert(str)

TyName=typename(StrText) //取变量StrText的类型给TyName
str1=left(StrText,6) //从StrText串中从左端取6位字符给str1
str2=mid(StrAdr,9,len(StrAdr)) //从StrAdr中中间第9位取长度为StrAdr串的长度的子字符串给str2
str=str1 & StrName & str2 // 3个字符串内容连接赋给str
alert(str) //弹出提示,其内容为str串的内容