-Log in
-Register (free)


-RSS Feeds
-New MyDesk Module
-Update to Profile

how to do a partial string compare
cheap kicks,cheap jordan 1 size 8-13 retro
cheap jordan kicks,cheap nike sb dunk shoes,cheap




 Forums /

asp array problem,Subscript out of range: 'Lbound'
tgonzo | Posted 3:37am 25. March 2009 Server Time |

hi there i ve got the following problem:
i got an error:Microsoft VBScript runtime error '800a0009',Subscript out of range: 'Lbound',/s/t/u/studentshareweb/probe/n3_class.asp, line 90

here is the code i used, the code works fine using const conArrDimension=2, i added an additional field conArrMemberRealCode and upgraded conArrDimension to 3 since then the error above happens, any ideas, please help, i can't find the problem:


<%
Option Explicit
Const conArrDimension = 3
Const conArrMemberUserName = 0
Const conArrMemberPassword = 1
Const conArrMemberRealName = 2
Const conArrMemberRealCode = 3

Const conVersion = "0.6"

Class n3_MembersFree

Private m_blnLogIn
Private m_blnMembers
Private m_txtUser
Private m_txtPassword
Private m_blnForm
Private m_realName
Private m_realCode
Private m_action
Private arrMembers
Private i


Public page
Public caption
Public blnLogIn
Public realName
Public realCode

Private Sub Class_Initialize()
m_blnLogIn = False
m_txtUser = Server.HTMLEncode(Trim(Request.Form("txtUser")))
m_txtPassword = Server.HTMLEncode(Trim(Request.Form("txtPassword")))
m_blnForm = Server.HTMLEncode(Request.Form)
m_action = Lcase(Request.QueryString("action"))

page = "http://studentshareweb.brinkster.net/probe/index.asp"
caption = "Members Only Access"
blnLogIn = m_blnLogIn
realName = Null
        realCode = Null
    
End Sub

Private Sub Class_Terminate()
' terminate
End Sub

Public Function membersFreeVersion()
End Function

Public Function logOutLink()
logOutLink = "<a href=""" & page & "?action=LogOut"">Log Out</a>"
End Function

Private Sub initMembers()
ReDim arrMembers(conArrDimension,0)
m_blnMembers = True
i = 0
End Sub

Private Sub preserveMembers()
ReDim Preserve arrMembers(conArrDimension,i)
End Sub

Public Sub addMember(UserName,Password,RealName,RealCode)
If IsEmpty(m_blnMembers) Then initMembers()
If (UserName <> "") And (Password <> "") And (RealName <> "") And (RealCode <> "") Then
arrMembers(conArrMemberUserName,i) = UserName
arrMembers(conArrMemberPassword,i) = Password
arrMembers(conArrMemberRealName,i) = RealName
arrMembers(conArrMemberRealCode,i) = RealCode
i = i + 1
If IsArray(arrMembers) Then preserveMembers()
End If
End Sub

Public Sub checkMember()
If Not IsArray(arrMembers) Then
caption = "<span class=""n3-error"">No members have been added to the allowed members " & _
"list. Use the config.asp file to add members as needed.</span>"
Exit Sub
End If

i =i-1
preserveMembers()


For i = (Lbound(arrMembers,conArrDimension) To Ubound(arrMembers,conArrDimension)
If (StrComp(m_txtUser, arrMembers(conArrMemberUserName,i), 1) = 0) And _
(strComp(m_txtPassword, arrMembers(conArrMemberPassword,i), 1) = 0) Then
m_realName = arrMembers(conArrMemberRealName,i)
m_realCode = arrMembers(conArrMemberRealCode,i)

m_blnLogIn = True
Exit For
End If
Next











sessionState()
End Sub

I ve to shorten the code !!!


End Class

%>

lymanknap | Posted 5:23pm 5. August 2010 Server Time |

rzvs1a  <a href="http://sgrjfnjaoabr.com/">sgrjfnjaoabr</a>, [url=http://axuttfavavfh.com/]axuttfavavfh[/url], [link=http://wgrskqtgiful.com/]wgrskqtgiful[/link], http://vzumwcueihhx.com/
lymanknap | Posted 4:27pm 7. August 2010 Server Time |

http://www.whatsatararrel.com/online-home-insurance.html online home insurance %( http://www.vallalkozofiatalok.com/ cheap auto insurance 7956 http://www.iphoneobserver.com/cheap-life-insurance.html life insurence 253449 http://www.wellspringis.org/ discount auto insurance :-PPP http://www.tarinthai.com/lifeinsurancequotes.html fort dearborn life insurance :-]
choonchan | Posted 5:39am 11. August 2010 Server Time |

http://www.mega1031.org/ home insurance 940870 http://www.autosinsurancequotes4u.com/ auto insurance rates 495783 http://www.buycheaphomeinsurance.com/ home owners insurance quote jkau http://www.cheapinsurancemate.com/ cheapest insurance %-PPP
mkaymer | Posted 5:53am 20. August 2010 Server Time |

http://www.maddonnasnashville.com/cialis.php cialis 621
mkaymer | Posted 4:11pm 22. August 2010 Server Time |

http://www.buycheaphomeinsurance.com/ cheap home insurance 8-) http://www.autosinsurance4u.com/ auto insurance =-[[ http://www.findcarinsurancequotes.net/ car insurance quotes ssk
1
Show all replies to 'asp array problem,Subscript out of range: 'Lbound''
To post a message to this discussion you need to be
a Haneng.com member. If you already are a member please log in
if not register as a member here (free).



| Info |
© Copyright 1997-2010 Alexander Haneng