This topic is locked

VB Question

5/19/2004 6:43:36 AM
ASPRunnerPro General questions
author

Hi,

I know this must be something "stupid". I have a select box and based upon that selection (if "poor" or "unacceptable") they must fill out another question. I must not be referring to the value of the array correctly. Thanks for the assistance... Bandit
The select box
if "StockCondition" = strName then strSize = 1 : arr = Array("Excellent", "Good", "Fair", "Poor", "Unacceptable") end if
The validation
<%

if Request.Form("StockCondition")= "3" AND Request.Form("StockDetails")= "" then

%>

<tr bgcolor="#cccccc">

<td height="26" bgcolor="#ccccff"><b>You need to state the stock details.</b></td>

</tr>

<% end if %>

<%

if Request.Form("StockCondition")= "4" AND Request.Form("StockDetails")= "" then

%>

<tr bgcolor="#cccccc">

<td height="26" bgcolor="#ccccff"><b>You need to state the stock details.</b></td>

</tr>

<% end if %> <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=question&id=604&image=1&table=forumtopics' class='bbc_emoticon' alt=':P' />

Sergey Kornilov admin 5/19/2004

Here is what you can try:

<%

if (Request.Form("StockCondition")= "Poor" OR Request.Form("StockCondition")= "Unacceptable" ) _

AND Request.Form("StockDetails")= "" then

%>

<tr bgcolor="#cccccc">

<td height="26" bgcolor="#ccccff"><b>You need to state the stock details.</b></td>

</tr>

<% end if %>


I hope this helps.