Click to See Complete Forum and Search --> : if else help.


Rterres
07-21-2006, 02:05 AM
Ok. asp lovers..
im asking for some help!!!

i have this pice of code with 3 if statements
but is not working...
i think is a sytax error but the page doesnt mean to work....

if anyone have any suggestions i will appreciate!!!!!
thanks
Regards for all
RT

<input type=text name=box value="<% if (FP_FieldVal(fp_rs,"reciboa_nombre"))="inquilino1" Then
Response.Write (FP_FieldVal(fp_rs,"Nombre_completo_inq"))

(ElseIf (FP_FieldVal(fp_rs,"reciboa_nombre"))="arrendador2" Then
Response.Write (FP_FieldVal(fp_rs,"Nombre_comp")))

(Else
Response.Write(FP_FieldVal(fp_rs,"Nombre_fiador")))
End IF%>"

lmf232s
07-21-2006, 08:38 AM
Try a different approach. You dont have to do this all in the value section of the input box.

<%
Dim Temp
If FP_FieldVal(fp_rs, "reciboa_nombre") = "inquilino1" then
Temp = FP_FieldVal(fp_rs, "Nombre_completo_inq")
ElseIf FP_FieldVal(fp_rs, "reciboa_nombre") = "arrendador2" then
Temp = FP_FieldVal(fp_rs, "Nombre_comp")
Else
Temp = FP_FieldVal(fp_rs,"Nombre_comp")
End If
%>
<input type=text name=box value="<%=Temp%>">

Rterres
07-21-2006, 07:38 PM
ok..
thanks for the help...

im working on it!!!
thaks!!
and regards for allllll!!!!
Rt