df75douglas
Programmer
Hello I would like to print the concatenation of the first 2 boxes in the 3rd, any idea what im doing wrong
<html>
<head>
<script language = "vbscript">
Dim word1, word2, result
function cmdUserInfnClick()
if len(form.word1.value)<3 then
msgbox("please use atleast 3 characters in the first box")
form.word1.focus
form.word1.select
elseif len(form.word2.value) <3 then
msgbox("please use atleast 3 characters in the second box")
form.word2.focus
form.word2.select
else
response.write(form.result.value(word1 + word 2))
end if
end function
</script>
</head>
<BODY> <div align ="center">
<form name = "form" method = "post">
<table border="1">
<tr>
<td>3 Character string:</td><td><input type = "text"name = "word1" size="15"></td>
</tr>
<tr>
<td>3 Character string:</td><td><input type = "text" name = "word2" size="15"></td>
</tr>
<tr>
<td>Concatenated string:</td><td><input type = "text"name ="result" size="15"></td>
</tr>
<tr>
<td><input type = "button" name = "cmdUserInfo" value = "Summit"size="15"></td>
</tr>
</table>
</form></div>
</body>
</html>
<html>
<head>
<script language = "vbscript">
Dim word1, word2, result
function cmdUserInfnClick()
if len(form.word1.value)<3 then
msgbox("please use atleast 3 characters in the first box")
form.word1.focus
form.word1.select
elseif len(form.word2.value) <3 then
msgbox("please use atleast 3 characters in the second box")
form.word2.focus
form.word2.select
else
response.write(form.result.value(word1 + word 2))
end if
end function
</script>
</head>
<BODY> <div align ="center">
<form name = "form" method = "post">
<table border="1">
<tr>
<td>3 Character string:</td><td><input type = "text"name = "word1" size="15"></td>
</tr>
<tr>
<td>3 Character string:</td><td><input type = "text" name = "word2" size="15"></td>
</tr>
<tr>
<td>Concatenated string:</td><td><input type = "text"name ="result" size="15"></td>
</tr>
<tr>
<td><input type = "button" name = "cmdUserInfo" value = "Summit"size="15"></td>
</tr>
</table>
</form></div>
</body>
</html>