那就这样写。
Dim colNames() As String = {"金额|第五列", "金额2|第六列", "金额3|第七列", "金额4|第八列"} 这里定义变量了数组
Dim count As Integer = 0
For Each colname As String In colNames 这里循环变量遍历数组
With Tables("表A")
Dim money As String = .Current(colname.split("|")(0)) 这里定义变量数值的值
If money <> 0 Then
rt.Cells(count+2,4).Text = colname.split("|")(1) 这里将指定行的文本等于数组