ASP type mismatch error - can't figure out why !!!

ASP type mismatch error - can't figure out why !!!

Post by Shaig » Wed, 19 Feb 2003 04:55:33



I am trying to submit a form and pass a variable through. My code is:

<form action="main.asp" name="formlogin">
        <input type="hidden" name="link" value="doLogin">
        <input type="hidden" name="dfile" value=""" & <% dlFile %> & """ >

I get a type mismatch error on the third line above. What am I doing wrong ?

 
 
 

ASP type mismatch error - can't figure out why !!!

Post by Bob Butl » Wed, 19 Feb 2003 08:44:19



> I am trying to submit a form and pass a variable through. My code is:

> <form action="main.asp" name="formlogin">
>    <input type="hidden" name="link" value="doLogin">
>    <input type="hidden" name="dfile" value=""" & <% dlFile %> & """ >

> I get a type mismatch error on the third line above. What am I doing wrong ?

<input type="hidden" name="dfile" value=""" & <%=dlFile%> & """ >

 
 
 

ASP type mismatch error - can't figure out why !!!

Post by Bob Butl » Wed, 19 Feb 2003 08:47:16



> I am trying to submit a form and pass a variable through. My code is:

> <form action="main.asp" name="formlogin">
>    <input type="hidden" name="link" value="doLogin">
>    <input type="hidden" name="dfile" value=""" & <% dlFile %> & """ >

> I get a type mismatch error on the third line above. What am I doing wrong ?

I sent that too quickly...

<input type="hidden" name="dfile" value="<%=dlFile%>" >

If this were inside a VBScript section using the response object it would be:
response.write "<input type=""hidden"" name=""dfile"" value=""" & _
         dlFile & """ >"

you were incorrectly combining the two formats

 
 
 

ASP type mismatch error - can't figure out why !!!

Post by ravr » Wed, 19 Feb 2003 09:19:39


<input type="hidden" name="dfile" value="<%= dlFile %>">

> I am trying to submit a form and pass a variable through. My code is:

> <form action="main.asp" name="formlogin">
>    <input type="hidden" name="link" value="doLogin">
>    <input type="hidden" name="dfile" value=""" & <% dlFile %> & """ >

> I get a type mismatch error on the third line above. What am I doing wrong ?