Solved

ASP - Microsoft VBScript compilation error '800a0411'  Name redefined

Posted on 2011-03-08
6
1,549 Views
Last Modified: 2012-05-11
I am migrating an ASP app to IIS6 from IIS5 it would appear that the global application object is handled differently. In the app currently the there is an include line for each page to include the global variable e.g. <!-- #include file="inc/applicationVariables.asp" -->

However when you go from one page to another I get the error in the title. It appears it is moaning about a constant value being changed (I guess 'cus it's re-reading it..?) However if I remove the include file line then I get an error saying:

Microsoft VBScript runtime error '800a01a8'
Object required: 'application(...)'
0
Comment
Question by:Lico_w
  • 4
  • 2
6 Comments
 
LVL 29

Expert Comment

by:Paul Jackson
Comment Utility
Remove the constant out into another file and only include that in your initiaal page, or just put the constant at the top of your initial page.
0
 

Author Comment

by:Lico_w
Comment Utility
No good, when I do either it states my variables haven't been declared when I move to the next page. For example:

Microsoft VBScript runtime error '800a01f4'
Variable is undefined: 'applicationRoot'

Any ideas how I can set these global variables without re-declaring them?
0
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 250 total points
Comment Utility
Instead of using a global variable in this way use a Application variable if the variable/constant is the same for all users or session variable if it changes depending on the user.

i.e

Application("applicationRoot") = "somevalue"
or
Session("applicationRoot") = "somevalue"

You should have no problems with this being in the include file no matter how many times the include file is copied in.

When you want to retrieve the value :

dim myVariable = Application("applicationRoot")
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:Lico_w
Comment Utility
OK thanks, will award points soon, but want to keep Q open for a couple of days whilst I reconfigure.
0
 

Assisted Solution

by:Lico_w
Lico_w earned 0 total points
Comment Utility
This issue was related to the fact the global.asa was not being seen as the global variables for the app. I had to configure a Virtual Directory to resolve the issue. That allowed me to declare the const values
0
 

Author Closing Comment

by:Lico_w
Comment Utility
.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now