作业帮 > 综合 > 作业

Function fw(x,ra As Range) Dim r1 As Range For Each r1 In ra

来源:学生作业帮 编辑:作业帮 分类:综合作业 时间:2024/11/09 03:02:04
Function fw(x,ra As Range) Dim r1 As Range For Each r1 In ra If r1.text = x And InStr(1,r1.F
ormula,"=TT(") > 0 Then
fw = fw & Split(Split(r1.Formula,"(")(1),",")(0) & ","
End If
Next r1
If fw = "" Then fw = "没有"
End Functio
这个能做成输出地址对应的数据吗?(地址:指上面VBA输出的地址)
Function fw(x,ra As Range)
Dim r1 As Range,f1$,f2
For Each r1 In ra
If r1.Text = x And InStr(1,r1.Formula,"=tt(") > 0 Then
f1 = Split(Split(r1.Formula,"(")(1),",")(0)
f2 = Range(f1)
fw = fw & f1 & "," & f2 & ","
End If
Next r1
If fw = "" Then fw = "没有"
End Function