How-de-doo-de
I'm using VBscript to withdraw data from an oracle table, and want to display said data in a flashy html table. I'm getitng an error message on the following bit of code and I'm stuck (so to speak). There are 7 fields and multiple records in each field. I want to draw them all out, assign the records for each field to individual arrays and then place into an HTML table. The error I get is
<-- subscript out of range -->
Heres the bit thats falling over:
cmmSQL= "SELECT StartDateTime, EndDateTime, DurationSecs, CallersNumber, DialledNumber,TerminatingNumber, ValuePence FROM Opal_Data WHERE TerminatingNumber = '" & PRS & "' "
Set rsCDR = cnAcqAcc.Execute( cmmSQL )
rsCDR.MoveFirst
i = 1
While not rsCDR.EOF
CDRs1(i)=rsCDR.Fields("StartDateTime") 'error msg is here
CDRs2(i)=rsCDR.Fields("EndDateTime")
CDRs3(i)=rsCDR.Fields("DurationSecs")
CDRs4(i)=rsCDR.Fields("CallersNumber")
CDRs5(i)=rsCDR.Fields("DialledNumber")
CDRs6(i)=rsCDR.Fields("TerminatingNumber")
CDRs7(i)=rsCDR.Fields("ValuePence")
i = i + 1
Wend
can anyone shed a liitle light 'cos it looks like it should work to me?
Cheers 'n' Beers




Reply With Quote