Hi there,
I got the ASP code as follows:
file1.asp
*****************************************************
<%
If a = 10 then
%>
<!--#include file="general.asp"-->
and do something
<%
ElseIf a =20 then
%>
<!--#include file="general.asp"-->
and do something
<%
Else
<!--#include file="general.asp"-->
and do something
<%
End If
%>
*************************************
general.asp
***********************************
<%
Dim a,b
Response.Write(a)
.
.
and so on...
%>
***********************************
When I tried to run this file1.asp I got the following error:
Microsoft VBScript compilation (0x800A0411)
Name redefined
I understand that this error occurs when you tried to do
Dim for the same variable more than once. I do include the file two to three times in the file1.asp. But you can see that I include it on a conditional basis. So it is included only once and there is no possibility of getting this error.
But I still get the error. So please help me solve the problem.
Thank you very much.
Faheem Hameed
I got the ASP code as follows:
file1.asp
*****************************************************
<%
If a = 10 then
%>
<!--#include file="general.asp"-->
and do something
<%
ElseIf a =20 then
%>
<!--#include file="general.asp"-->
and do something
<%
Else
<!--#include file="general.asp"-->
and do something
<%
End If
%>
*************************************
general.asp
***********************************
<%
Dim a,b
Response.Write(a)
.
.
and so on...
%>
***********************************
When I tried to run this file1.asp I got the following error:
Microsoft VBScript compilation (0x800A0411)
Name redefined
I understand that this error occurs when you tried to do
Dim for the same variable more than once. I do include the file two to three times in the file1.asp. But you can see that I include it on a conditional basis. So it is included only once and there is no possibility of getting this error.
But I still get the error. So please help me solve the problem.
Thank you very much.
Faheem Hameed