'---constantes mémorisées---
Const ref1$ = "ID"
Const ref2$ = "% Rate"
Const ref3$ = "Paie"
Const ligref% = 3
Function TrouveValeur()
Application.Volatile
Dim nomfeuille$, nlig&, a(), i&, j%, w As Worksheet, c As Range, n&, lig&
nomfeuille = Application.Caller.Parent.Name
nlig = Application.Caller.Rows.Count
ReDim a(1 To nlig, 1 To 3)
For i = 1 To nlig: For j = 1 To 3: a(i, j) = "": Next j, i
For Each w In Worksheets
If w.Name <> nomfeuille Then
Set c = w.Cells.Find(ref1, , xlValues, xlWhole)
If Not c Is Nothing Then
n = n + 1
For lig = 1 To nlig
If n = lig Then
a(n, 1) = c.Offset(, 1)
On Error Resume Next
a(n, 2) = w.Cells.Find(ref2).Offset(, 1)
a(n, 3) = w.Cells.Find(ref3).Offset(, 1)
End If
Next lig
End If
End If
Next w
TrouveValeur = a 'matrice
End Function