IIF statements not working

S

Scott O'Donnell

From Win 2K Server, IIS 5, ASP

Is there a reason why Immediate If (IIF) statements won't run on an
IIS server?

I have code written on a dev server e.g.:

Response.Write IIF(1 = 1, "True", "False")

This code runs fine. However when I port it over to another server I
receive the following error:

Microsoft VBScript runtime error '800a000d'

Type mismatch: 'IIf'

/IIF test.asp, line 6

Is it possible I am missing a dll or something similar? Any help
would be greatly appreciated!

thanks in advance for any help
scott
 
B

Bob Barrows [MVP]

Scott said:
From Win 2K Server, IIS 5, ASP

Is there a reason why Immediate If (IIF) statements won't run on an
IIS server?

IIF is not a builtin vbscript function. You will have to write your own.

It's very helpful to have a quick "online" reference for questions like
these. The free MS searchable CHM file download with basic descriptions and
syntax for both VBS and JS is here:

http://www.microsoft.com/downloads/...48-207d-4be1-8a76-1c4099d7bbb9&DisplayLang=en

HTH,
Bob Barrows
 
R

Ray at

IIF isn't a vbscript statement. Perhaps you want to use a select case
statement.

Ray at work
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,065
Latest member
OrderGreenAcreCBD

Latest Threads

Top