|
| |
|
|
harris
Posts: 27 Joined: 2/7/2002 From: Minnesota USA Status: offline
|
Use IF in display code? - 3/12/2002 18:34:55
Hi, Is there a way to use an IF statement in the following code such that it will display a:xx if the code is not blank (where xx is the code) or nothing if the code is blank. The way it is incorrectly working right now is that it is always displaying a: - even when the code is blank. <td>a:<%=FP_FieldVal(fp_rs,"code")%></td> Thank you!
|
|
|
|
Chameleon
Posts: 84 From: Springfield, MO Status: offline
|
RE: Use IF in display code? - 3/12/2002 22:45:58
You can always assign your FP value to a variable and the use an if statement if your DRW is on a diet. It would be something like... <%DIM strCode strCode = FP_FieldVal(fp_rs,"code") If FP_FieldVal(fp_rs,"code") = null then strCode = whatever Else strCode = not null value End If%> This is just a general example but you should be able to get what you need wth it.
|
|
|
|
William Lee
Posts: 1273 Joined: 1/25/2002 From: Singapore Status: offline
|
RE: Use IF in display code? - 3/13/2002 0:57:45
<td><%If NOT IsEmpty(FP_FieldVal(fp_rs,"code")) Then Response.Write "a:" & FP_FieldVal(fp_rs,"code") %></td> William Lee
|
|
|
|
harris
Posts: 27 Joined: 2/7/2002 From: Minnesota USA Status: offline
|
RE: Use IF in display code? - 3/14/2002 8:31:22
Thank you Chameleon & William! This is exactly what I was looking for!! Harris
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|