Asp Error 800a0009
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and
Microsoft Vbscript Runtime Error '800a0009' Subscript Out Of Range: 'ubound'
policies of this site About Us Learn more about Stack Overflow the vbs subscript out of range 800a0009 company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags microsoft vbscript runtime error activex component can't create object Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only
Microsoft Vbscript Runtime Error: Subscript Out Of Range
takes a minute: Sign up Microsoft VBScript runtime error '800a0009' up vote 1 down vote favorite I recently inherited a website in ASP, which I am not familiar with. Yesterday, one of the pages began to throw an error: Microsoft VBScript runtime error '800a0009' Subscript out of range: 'i' default.asp, line 19 Here is the code from lines 13-27: <% set
Subscript Out Of Range: '[number: 1]'
rs = Server.CreateObject("ADODB.Recordset") rs.open "SELECT * FROM VENDORS_LIST_TBL WHERE inStr('"& dVendorStr &"','|'&ID&'|')", Cn DIM dTitle(100), dDescription(100), dLink(100) i = 0 : Do while NOT rs.EOF : i = i + 1 dTitle(i) = rs.fields.item("dTitle").value dDescription(i) = rs.fields.item("dDescription").value dLink(i) = rs.fields.item("dLink").value : if dLink(i) <> "" then dTitle(i) = "" & dTitle(i) & "" if NOT rs.EOF then rs.movenext Loop x = i rs.Close : Set rs = Nothing %> Any ideas on what's going on here and how I can fix it? Thank you! asp-classic runtime-error share|improve this question edited Jun 17 '12 at 22:02 Cheran Shunmugavel 6,10211732 asked Jun 16 '12 at 14:37 Patrick Appelman 3017 1 You might consider the ADO Recordset's GetRows method which returns atwo dimensional array. –AnthonyWJones Jun 16 '12 at 18:49 In light of the other two answers it is necessary to provide you with a "this is how this should be done" sort of answer. –AnthonyWJones Jun 18 '12 at 12:50 add a comment| 3 Answers 3 active oldest votes up vote 1 down vote acc
Detected You currently have javascript disabled. Several functions may not work. Please re-enable javascript to access full functionality. Microsoft Vbscript Runtime Error '800A0009' Subscript Out Of Range: subscript out of range: '[number: 0]' '[Number: 0]' Started by adnan13, Jan 02 2012 02:24 PM Please log in
Microsoft Vbscript Runtime Error 800a0046
to reply 4 replies to this topic #1 adnan13 adnan13 Newbie Members 4 posts Posted 02 January 2012 - subscript out of range in vbscript 02:24 PM I have got one error in opening page inmy website, actually this sources are old and i am not familiar with this.. plz help me.. Error: Microsoft VBScript runtime error http://stackoverflow.com/questions/11064329/microsoft-vbscript-runtime-error-800a0009 '800a0009' Subscript out of range: '[number: 0]' /rescontrol/Default.asp, line 72 Plz check out here this link http://desert.somee.com/rescontrol/ Full Source Code can be found in http://pastebin.com/QthvEubE function DecryptData(s)dim spdim dStrdim decry_stratdim decry_strdim decrdim i,tempdStr=ssp=split(dStr,"Z")decry_strat=eval(mid(sp(0),2,1)) i get error over here when i try to open page decr=decry_strat'Response.write Chr(sp(1)) 'Response.Write ubound(sp)for i=2 to ubound(sp)decry_str=decry_str & chr(cint("&H" + sp(i-1))-decr)decr=decr + decry_strat next DecryptData =decry_str end function Back http://w3schools.invisionzone.com/index.php?showtopic=41313 to top #2 adnan13 adnan13 Newbie Members 4 posts Posted 03 January 2012 - 06:41 AM any help??? pz.. Back to top #3 justsomeguy justsomeguy More Human Than Human Moderator 29,439 posts Gender:Male Location:Phoenix Languages:Focusing on PHP and JavaScript Posted 03 January 2012 - 08:19 PM A subscript out of range means you're trying to access an item that doesn't exist. If the split results in 3 items, and you try to access the fourth one, you'll get that error. Know your history: Babbage | Lovelace | Turing | Hopper | RitchieConTEXT Sublime Text Opera PHP MySQL phpMyAdminUse a debugger: Firefox, IE, Chrome, Safari, or OperaKnow the foundations of computer science: algorithms, machine architectures, data structures, etc. Don't just blindly copy techniques from application to application. Know what you are doing, that it works, and why it works. Don't think you know what the industry will be in five years time or what you'll be doing then, so gather a portfolio of general and useful skills. Try to write better, more principled code. Work to make "programming" more of a professional activity and less of a low-level "hacking" activit
Web Platform Installer Get Help: Ask a Question in our Forums More Help Resources Blogs Forums Home IIS.NET Forums IIS 7 and Above http://forums.iis.net/t/1185768.aspx?Microsoft+VBScript+runtime+error+800a0009+Subscript+out+of+range+number+0+ Troubleshooting Microsoft VBScript runtime error '800a0009' Subscript out of range: '... https://bytes.com/topic/asp-classic/answers/925624-microsoft-vbscript-runtime-error-800a0009 Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: 0]' RSS 6 replies Last post Jan 04, 2012 11:28 PM by HCamper ‹ Previous Thread|Next Thread › Print Share Twitter Facebook Email Shortcuts Active Threads Unanswered Threads Unresolved Threads Advanced Search Reply althamas subscript out kar... 4 Posts Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: 0]' Jan 01, 2012 03:57 AM|althamas karani|LINK I have got one error in opening page inmy website, actually this sources are old and i am not familiar with this.. plz help me.. Error: Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: subscript out of 0]' /rescontrol/Default.asp, line 72 Plz check out here this link http://desert.somee.com/rescontrol/ Source Code can be found in http://pastebin.com/QthvEubE function DecryptData(s) dim sp dim dStr dim decry_strat dim decry_str dim decr dim i,temp dStr=s sp=split(dStr,"Z") decry_strat=eval(mid(sp(0),2,1)) decr=decry_strat 'Response.write Chr(sp(1)) 'Response.Write ubound(sp) for i=2 to ubound(sp) decry_str=decry_str & chr(cint("&H" + sp(i-1))-decr) decr=decr + decry_strat next DecryptData =decry_str end function Reply Uk-Sam 201 Posts Re: Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: 0]' Jan 01, 2012 06:35 AM|Uk-Sam|LINK Subscript out of range usually states that your code is trying to access the element of an array that is either greater or lower than its ubound / lbound Reply althamas kar... 4 Posts Re: Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: 0]' Jan 01, 2012 09:18 AM|althamas karani|LINK can u help me to fix it?? or should i do that?? Reply althamas kar... 4 Posts Re: Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: 0]' Jan 01, 2012 09:36 A
Question Need help? Post your question and get tips & solutions from a community of 418,440 IT Pros & Developers. It's quick & easy. Microsoft VBScript runtime error '800a0009' P: 2 Gavin MUNJANJA Hi Guys can you please assist im getting Below error Microsoft VBScript runtime error '800a0009' Microsoft VBScript runtime error '800a0009' Subscript out of range: '[number: 3]' /asp_classes/textschema.asp, line 99 Below is my ASP Code <% class clsTextSchema dim objTables private sub Class_Initialize set objTables = new clsTextSchemaTables end sub public property get Tables Set Tables = objTables end property public function TableExists(tablename) dim tblfound dim i tblfound = false for i = 0 to objTables.Count -1 if lcase(objTables.Item(i).Name)=lcase(tablename) then tblfound = true exit for end if next TableExists = tblfound end function sub Save(pathname) dim objFSO dim schemaStrm dim i dim myTable dim fielddesc Set objFSO = server.CreateObject("Scripting.FilesystemObject") set schemaStrm = objFSO.OpenTextFile(pathname,2, true) 'ForWriting for i = 0 to objTables.Count -1 set myTable = objTables.item(i) schemaStrm.WriteLine "[" & myTable.name & "]" ' if myTable.blColNameHeader=true then ' schemaStrm.WriteLine "ColNameHeader=True" ' else schemaStrm.WriteLine "ColNameHeader=False" ' end if schemaStrm.WriteLine "Format=Delimited(|)" schemaStrm.WriteLine "CharacterSet=ANSI" for j = 0 to myTable.Fields.Count - 1 fielddesc = myTable.Fields.Item(j).name & " " & myTable.Fields.Item(j).DataType if myTable.Fields.Item(j).Size <> -1 then fielddesc = fielddesc & " Width " & myTable.Fields.Item(j).Size end if schemaStrm.WriteLine "Col" & j+1 & "=" & fielddesc next next schemaStrm.close end sub sub Load(pathname) dim SchemaStrm dim objFSO dim linedata dim objTable dim tblCount dim coldata dim strFormat Set objTables = new clsTextSchemaTables set objFSO = server.CreateObject("Scripting.FileSystemObject") set SchemaStrm = objfso.OpenTextFile(pathname,1) 'ForReading tblCount = 0 Do while (not SchemaStrm.AtEndOfStream) linedata = trim(SchemaStrm.Readline) if linedata="" then elseif (left(linedata,1) = "[") AND right(lcase(linedata),5)=".asc]" then objTables.add mid(linedata,2,len(linedata)-2) tblCount = tblCount + 1 set CurrentTable = objTables.item(tblCount-1) elseif left(lcase(lin