|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
|
|
#1
|
|||
|
|||
|
If then statements?
I was wondering if it is possible for me to have If then statement in ASP. I want to run a query and need to use If then statements such as: If this is output, then run this query. Is there a way to do this? Thanks in advance.
|
|
#2
|
||||
|
||||
|
Yes, you can do an if-then statement in asp.
Code:
If condition Then do something Else do something else End If
__________________
--Dave-- U2kgSG9jIExlZ2VyZSBTY2lzLCBOaW1pdW0gRXJ1ZGl0aW9uaXMgSGFiZXM= |
|
#3
|
|||
|
|||
|
Thanks!
I am trying to do this: If sResult1 = sOutput11 then response.write "aaaaaa" else objrs.movenext end if Is that right? It wont work. What am i missing? |
|
#4
|
|||
|
|||
|
ASP is not a language, Be more specific, are you using vbscript or javascript?
what's the error message? are you putting it in <% %> brackets? if it's javascript you'll have to use if this == that { } else { } Keep in mind, if this IS vbscript and it's in a loop, then your if never says movenext, so it's caught in a loop, does your page get stuck and never move? If so make sure you increment your RS. Last edited by unatratnag : August 20th, 2003 at 09:18 AM. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > If then statements? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|