800a0409 Vbscript Compilation Error
Contents |
800A0409 - Unterminated string constant An easy error to cure, especially if you count the Char: number. Naturally, start at the beginning of the line referenced in the error microsoft vbscript compilation error '800a0400' message. Solving 800A0409 really is that easy. Introduction to Error Code 800A0409 This
Vbscript Compilation Error Expected Statement
error code, 800A0409 usually occurs when you execute a VBScript. Most likely you have left out a closing speech
Microsoft Vbscript Compilation Error '800a0401'
mark or bracket. The Symptoms You Get Windows Scripting host generates a message box like this. The script does not execute as you would have hoped. A possible scenario is that
Vbscript Compilation Error '800a03ea'
you are trying to create a Windows logon script. The Cause of Error 800A0409 Your VBScript lacks a closing punctuation mark at the end of a line. If I could emphasise, look at the end of the line not the beginning. To help you, pay close attention to the Char: number, in my example, 57. One nasty variation of Error 800A0409 is where you vbscript compilation error expected end of statement mix up single and double quote marks. Source: Microsoft VBScript compilation error, which means it a syntax errorin your script, rather than a runtime error. The Solution Check the syntax of your script, particularly for closing statements, speech marks or brackets. Look for clues, count all the lines including blank lines and 'REM lines. In this example the problem is at Line:2. In this case the Char: number (57) is particularly useful for identifying the missing speech mark.If you are still stuck then a good script editor really would help this type of problem because it color codes the commands. Free download of OnScript. ‡ Example Script for error 800A0409 Set WshNetwork = WScript.CreateObject("WScript.Network) Missing speech mark Set WshNetwork = WScript.CreateObject("WScript.Network") Corrected version Set WshShell = WScript.CreateObject("WScript.Shell") Set WshNetwork = WScript.CreateObject("WScript.Network) Set AllDrives = WshNetwork.EnumNetworkDrives() DriveLetter = "N:" 'must be capitalized RemotePath = "\\alan\home" AlreadyConnected = False For i = 0 To AllDrives.Count - 1 Step 2 If AllDrives.Item(i) = DriveLetter Then AlreadyConnected = True Next If AlreadyConnected = False then WShNetwork.MapNetworkDrive DriveLetter, RemotePath WshShell.PopUp "Drive " & DriveLetter & " connected oK." Else WShNetwork.RemoveNetworkDrive DriveLetter WshShell.Pop
Unanswered Topics Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Basics Error: Microsoft VBScript compilation error vbscript compilation error name redefined '800a0409' User Name Remember Me? Password Reminder Password Register Register | FAQ | vbscript compilation error cannot use parentheses when calling a sub Members List | Calendar | Today's Posts | Search Classic ASP Basics For beginner programmers starting with "classic" vbscript compilation error expected identifier ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0 Search Forums Show Threads Show Posts Advanced Search Find All Thanked Posts Go to Page... Welcome to the p2p.wrox.com Forums. http://www.computerperformance.co.uk/Logon/code/code_800A0409.htm You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the http://p2p.wrox.com/classic-asp-basics/72519-error-microsoft-vbscript-compilation-error-800a0409.html ads that are displayed to guests. Registration is fast, simple and absolutely free . Thread Tools Display Modes #1 (permalink) February 2nd, 2009, 10:27 AM webXtreme Authorized User Join Date: Nov 2006 Location: Washington, DC, . Posts: 14 Thanks: 2 Thanked 0 Times in 0 Posts Error: Microsoft VBScript compilation error '800a0409' I'm getting the following error message when I try to run my ASP page: Microsoft VBScript compilation error '800a0409' Unterminated string constant /policy/ecwsi/policy_states/state_policy.asp, line 20 strSQL = "select [idPS] as ID,[state],[titlePS] as title,[integPS],[qualityPS],[diversityPS],[compPS],'Professional Standards' as rowHeader,1 as sortKey from [profStandards] where [state]='Arkansas' ----------------------------------------------------------^ Here's my code: (PLEASE HELP - I need this fixed for our funders) <% 'Dimension variables Dim rs, connStr, strSQL ' Recordset Object Set connStr = Server.CreateObject("ADODB.Connection") Set rs = Server.CreateObject("ADODB.Recordset") ' Defining database connection connStr.ConnectionString = path connStr.Provider = provider connStr.open strSQL = "select [idPS] as ID,[state],[titlePS] as title,[integPS],[qualityPS],[diversityPS],[compPS],'Professional Standards' as rowHeader,1 as sortKey from [profStandards] where [state]='Arkansas' Union select [idF] as ID, [state],[titleF] as title,[integF],[qualityF],[diversityF],[compF],"Finance" as rowHeader,6 as sortKey from [finance] where [state]="Arkansas" UNION select[idAS] as ID, [state],"Overarching: " & [titleAS] & "
Professio
Unterminated string constant If this is your first visit, be sure to check out the FAQ http://www.vbforums.com/showthread.php?9758-Microsoft-VBScript-compilation-error-'800a0409'-Unterminated-string-constant by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. Results 1 to 2 of 2 Thread: Microsoft VBScript compilation error '800a0409' Unterminated string constant vbscript compilation Tweet Thread Tools Show Printable Version Subscribe to this Thread… Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode Jan 26th, 2000,04:26 AM #1 HakanAzaklioglu View Profile View Forum Posts Thread Starter Member Join Date Jan 2000 Posts 63 Newbie needing assistance... Dunno what to do next... I am vbscript compilation error attempting a query on line 95... Error message is: Microsoft VBScript compilation error '800a0409' Unterminated string constant /888.asp, line 95 cmdTemp.CommandText = "SELECT CIEmpdir2.`Location`, Stores.Stores_ID, '<% response.write RSDepartments ------------------------------------------------------------------------------------------------------^ Code is as follows: <%@ LANGUAGE="VBSCRIPT" %> <% set conn = server.createobject ("adodb.connection") conn.open "ASPBook", "sa", "yourpassword" set RSDepartments = conn.Execute("SELECT CIEmpDir2.EmpWorkPhone FROM CIEmpDir2 WHERE (((CIEmpDir2.Star)>'')) ") %>
<%Manufacturer = Request.Form("Manufacturer")%>Auto Listing Page
<% Set DataConn = Server.CreateObject("ADODB.Connection") DataConn.ConnectionTimeout = Session("DataConn_ConnectionTimeout") DataConn.CommandTimeout = Session("DataConn_CommandTimeout") DataConn.Open "ASPBook", "sa", "yourpassword" Set cmdTemp = Server.CreateObject("ADODB.Command") Set DataCommand1 = Server.CreateObject("ADODB.Recordset") cmdTemp.CommandText = "SELECT CIEmpDir2.Location FROM CIEmpDir2 WHERE (((CIEmpDir2.Star)>''))" cmdTemp.CommandType