Which cell did my formula find?

  • Thread starter Thread starter SLOGIC
  • Start date Start date
S

SLOGIC

I have a MIN formula reading vendor bids across many worksheets in the
workbook. It works but I cannot see which worksheet the bid was on. Trace
Precedent doesn't work.
 
I have a couple of ideas (untested) but I am curious as to what the exact
formula is.

IDEAS:
Once you find the MIN value have a cell that uses the IF function along with
the MIN formula to display the vendor: IF(MIN(....)=B1,vendorname,.....).
B1 would be the MIN formulat that works. Vendorname would be the vendor
pulled from the sheet that has the MIN value that was found.

Another idea is if the same MIN formula can be placed in a conditional
format. Then the format can change on the vendor that meets the criteria.

Again, untested, but a couple of ideas that popped in my head.

Les
 
Select the cell containing the MIN formula and run this macro:

Sub WhereIsIt()
v = ActiveCell.Value
mesage = ""
For Each w In Worksheets
For Each r In w.UsedRange
If IsNumeric(r.Value) Then
If r.Value = v Then
mesage = mesage & w.Name & r.Address & Chr(10)
End If
End If
Next
Next
MsgBox (mesage)
End Sub

This will find the sheet containing the min value and the cell as well. If
there is more than one occurance of the minimum, all occurances will be
returned.
 
Gary''s Student said:
Select the cell containing the MIN formula and run this macro:

Sub WhereIsIt()
v = ActiveCell.Value
mesage = ""
For Each w In Worksheets
For Each r In w.UsedRange
If IsNumeric(r.Value) Then
If r.Value = v Then
mesage = mesage & w.Name & r.Address & Chr(10)
End If
End If
Next
Next
MsgBox (mesage)
End Sub

This will find the sheet containing the min value and the cell as well. If
there is more than one occurance of the minimum, all occurances will be
returned.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top