That's the same program with the structure of the first SELECT:
Code:
<script language="VBScript">
<! -
Select Case Month (Now ())
houses 1,2,3
document.write "We are in the first quarter."
houses 4,5,6
document.write "We are in the second quarter."
houses 7,8,9
document.write "We are in the third quarter."
Case Else
document.write "We are in the fourth quarter."
End Select
//-->
</ Script>
In this structure, you define the variable to be controlled with the statement "Select Case Variable", and are then lists the possible values that can take the variable with the statement "case value1, value2, value3" to follow these directions what to do. In the example the variable is numeric, if the string variable the values are put between quotation marks:
case "value1", "value2", "value3"
Bookmarks