Option Explicit

Results 1 to 3 of 3

Thread: Option Explicit

  1. #1
    mark Guest

    Default Option Explicit

    I am getting the following error when I try to use option explicit:<BR>Microsoft VBScript compilation error &#039 800a0400&#039 <BR>Expected statement <BR>OPTION EXPLICIT<BR>^<BR>Could this error be caused by trying to use a variable without declaring it? I&#039m switching my existing code to use this option because of an article I read that says it&#039s faster. If you want to look at it go to http://www.asptoday.com/articles/20000113.htm

  2. #2
    Join Date
    Dec 1969

    Default RE: Option Explicit

    Make sure you have no variables or other text other than<BR><BR>&#060;%Option Explicit%&#062;<BR>&#060;%Response.Buffer = True%&#062;<BR><BR>above you Option Explicit<BR><BR>Quotes are ok ie &#039hello<BR>and include files are ok but no other text should be above it.<BR><BR>Try it<BR><BR>Jez

  3. #3
    RedEyez. Guest

    Default RE: Option Explicit

    You get this message if &#060;%Option Explicit%&#062; is not the very first line of code in your asp page. Just a shot in the dark, but make sure this is the case.<BR><BR>Regards

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts