日期:2014-05-17  浏览次数:21429 次

一个简单的VBScript返回的是False!?郁闷!
<%@LANGUAGE= "VBSCRIPT "   CODEPAGE= "936 "%>
<html>
<head>
<title> Function   Test </title>
</head>

<body>
<%
Function   TestWord(Daxiaoxie)
  If   Daxiaoxie   > =   2   then  
    TestWord   =   "TESTWORD "
  Else
    TestWord   =   "testword "
  End   If
End   function  
Response.Write     "   大写的 "&   Daxiaoxie   =   3   & " <br> "
Response.Write     "   小写的 "&   Daxiaoxie   =   1   & " <br> "
%>
</body>
</html>

就这么点..返回是的     False   两个..

<html>
<head>
<title> 无标题文档 </title>
</head>

<body>
FalseFalse
</body>
</html>

超郁闷...

------解决方案--------------------
<html>
<head>
<title> Function Test </title>
</head>

<body>
<%
Function TestWord(Daxiaoxie)
If Daxiaoxie > = 2 then
TestWord = "TESTWORD "
Else
TestWord = "testword "
End If
End function
Daxiaoxie = 3
Response.Write " 大写的 " & TestWord(Daxiaoxie) & " <br> "
Daxiaoxie = 1
Response.Write " 小写的 " & TestWord(Daxiaoxie) & " <br> "
%>
</body>
</html>
------解决方案--------------------
TestWord函数没调用