shah2k
asked on
what is the error "Active Server Pages error 'ASP 0137' "?
Can anyone please help me what is the error about and why I get this error and how to solve it?
When i run any asp page i get the following error:
Active Server Pages error 'ASP 0137'
Invalid Global Script
//global.asa, line 1
Script blocks must be one of the allowed Global.asa procedures. Script directives within <% ... %> are not allowed within the global.asa file. The allowed procedure names are Application_OnStart, Application_OnEnd, Session_OnStart, or Session_OnEnd.
I dont know whats the problem ?can anyone tell me how i can solve the problem and make my asp page work.
Thanks.
When i run any asp page i get the following error:
Active Server Pages error 'ASP 0137'
Invalid Global Script
//global.asa, line 1
Script blocks must be one of the allowed Global.asa procedures. Script directives within <% ... %> are not allowed within the global.asa file. The allowed procedure names are Application_OnStart, Application_OnEnd, Session_OnStart, or Session_OnEnd.
I dont know whats the problem ?can anyone tell me how i can solve the problem and make my asp page work.
Thanks.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
That's strange. What jitganguly said is correct. Some information for you.
1. Global.asa should be placed in the root directory.
2. You should never make function calls to the 4 standard functions in the file.
3. Structure of the file is as below
<script language="VBScript" runat="Server">
Sub Session_onStart
' This will be invoked automatically when a session is started
End Sub
Sub Session_onEnd
' This will be invoked automatically when a session is abandaned/ended
End Sub
Sub Session_onStart
' This will be invoked automatically when a session is started
End Sub
Sub Application_onStart
' This will be invoked automatically when the web application is started.
End Sub
Sub Application_onEnd
' This will be invoked automatically when the web application is stopped.
End Sub
</script>
4. There shouldn't have any <%..%> in the file itself.
5. There shouldn't have any Response.Write in the file.
I suggest you post the content of the file here for view.
hongjun
1. Global.asa should be placed in the root directory.
2. You should never make function calls to the 4 standard functions in the file.
3. Structure of the file is as below
<script language="VBScript" runat="Server">
Sub Session_onStart
' This will be invoked automatically when a session is started
End Sub
Sub Session_onEnd
' This will be invoked automatically when a session is abandaned/ended
End Sub
Sub Session_onStart
' This will be invoked automatically when a session is started
End Sub
Sub Application_onStart
' This will be invoked automatically when the web application is started.
End Sub
Sub Application_onEnd
' This will be invoked automatically when the web application is stopped.
End Sub
</script>
4. There shouldn't have any <%..%> in the file itself.
5. There shouldn't have any Response.Write in the file.
I suggest you post the content of the file here for view.
hongjun
post your global.asa content please
post your global.asa content please
If everything works fine then why a 'B' ? Remember it is a free service and I spent some time solving your problem. Don't you appreciate it with a A grade.
Actually it was my mistake not looking at your history, I wouldn't have tried.
I will ask CS to change it to 'A'
Rgds
Jit
Actually it was my mistake not looking at your history, I wouldn't have tried.
I will ask CS to change it to 'A'
Rgds
Jit
ASKER
Thanks.