我在水晶报告中收到以下代码的“下标必须介于 1 和数组大小之间”。请帮忙!
'To Use Multiline if Basic Syntax was used
Shared Cust_Ids() As Number
Shared Page_No() As Number
Shared Cust_Ids2() As Number
Shared Page_No2() As Number
Local m As Number
Local i As Number
Local j As Number
Local Cnt As Number
j=1
i=1
Cnt=Count({CL_Index_Page_ttx.Customer_ID})
For i=1 To Cnt
If i <=1000 Then
If Cust_Ids(i) - {CL_Index_Page_ttx.Customer_ID} = 0 Then
m = Page_No(i)
i=Cnt+1
End If
Else
If Cust_Ids2(j) - {CL_Index_Page_ttx.Customer_ID} = 0 Then
m = Page_No2(j)
i=Cnt+1
Else
j=j+1
End If
End If
Next i
Formula=m