我的报告中有以下代码:
Dim suma As Decimal = New Decimal()
Public Function SumLookup(ByVal items As Object()) As Decimal
If items Is Nothing Then
Return Nothing
End If
Dim ct as Integer = New Integer()
suma = 0
ct = 0
For Each item As Object In items
suma += Convert.ToDecimal(item)
ct += 1
Next
If (ct = 0) Then return 0 else return suma
End Function
Public Function GetMyVal() as Decimal
GetMyVal = suma
End Function
上面的函数返回suma
,我通过以下方式调用该函数:
code.SumLookup(LookupSet(Fields!Claim_Currency.Value,Fields!Claim_Currency.Value,Fields!Total_Paid_Loss___LAE.Value, "dataSet"))
我想在我的报告suma
中使用这两个变量。ct
如何调整函数以使其返回两个变量,然后如何从报告中调用它们?