I want to redirect to a page if a variable is greater than 1 so I'm using
the following code but get an incorrect syntax error, can somebody please
tell me the correct syntax?

Cheers.

Code:

If iRecordCount = >1 then
response.redirect "test.asp"
End If

Re: An easy one I hope by Evertjan

Evertjan
Tue Aug 19 04:09:24 CDT 2003

Miguel Orrego wrote on 19 aug 2003 in
microsoft.public.inetserver.asp.general:

> I want to redirect to a page if a variable is greater than 1 so I'm using
> the following code but get an incorrect syntax error, can somebody please
> tell me the correct syntax?
>
> Cheers.
>
> Code:
>
> If iRecordCount = >1 then
> response.redirect "test.asp"
> End If
>

It is not English free-for-all, but a computer language:

If iRecordCount > 1 then


--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

Re: An easy one I hope by Tim

Tim
Tue Aug 19 07:28:13 CDT 2003

"Miguel Orrego" <miguel@stressedmonkey.net-nospam> wrote:

>I want to redirect to a page if a variable is greater than 1 so I'm using
>the following code but get an incorrect syntax error, can somebody please
>tell me the correct syntax?
>
>Cheers.
>
>Code:
>
>If iRecordCount = >1 then

You seem to have left a space between the equal sign and the greater
than sign, and you've got them in the wrong order. You're trying to
say "greater than or equal". The symbol for that is two characters: >=
with no space. So:

If iRecordCount >= 1 Then
>response.redirect "test.asp"
>End If
>


--
Tim Slattery
MS MVP(DTS)
Slattery_T@bls.gov