472,093 Members | 2,475 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,093 software developers and data experts.

MS VBScript Compilation error 800a0401

I have no idea what's wrong with the following ASP statement:

Response.Write "<select name=\"id\">"

MS VBScript Compilation error 800a0401
expected end of statement

However, if I do the following, it will be fine:

<select name="id">
<%

%>
</select>
any ideas??
Jul 19 '05 #1
2 8047
Response.Write "<select name=""id"">"

Within VBScript, you escape a " with another " and not \.

--
Manohar Kamath
Editor, .netBooks
www.dotnetbooks.com
"Matthew Louden" <jr********@hotmail.com> wrote in message
news:uf**************@TK2MSFTNGP09.phx.gbl...
I have no idea what's wrong with the following ASP statement:

Response.Write "<select name=\"id\">"

MS VBScript Compilation error 800a0401
expected end of statement

However, if I do the following, it will be fine:

<select name="id">
<%

%>
</select>
any ideas??

Jul 19 '05 #2
The \ character is used to escape characters in jscript, not vbscript. In
vbscript, you write "" to escape a " character in a string.
Response.Write "<select name=""id"">"

Ray at work

"Matthew Louden" <jr********@hotmail.com> wrote in message
news:uf**************@TK2MSFTNGP09.phx.gbl...
I have no idea what's wrong with the following ASP statement:

Response.Write "<select name=\"id\">"

MS VBScript Compilation error 800a0401
expected end of statement

However, if I do the following, it will be fine:

<select name="id">
<%

%>
</select>
any ideas??

Jul 19 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by JNariss | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.