Tooltips

  • Thread starter Thread starter Voodoodan
  • Start date Start date
V

Voodoodan

Hello!

This may be asking a lot from Excel, but is there a way to do th
following, in Excel 2000:

When you move the cursor over a cell with a date in it, for a toolti
to appear above it showing the difference in days between that date an
today?

Thanks,
Dan
 
Cells do not have tool tips. The nearest thing may be cell comments but
cell comments are static text. You could use a macro to add the comment
text you want to all date cells but it would have to be re-run every day.
This example works on date cells in the current selection.

Sub DateDiffToComment()
Dim Cell As Range
On Error GoTo ExitThis
For Each Cell In Selection.SpecialCells(xlCellTypeConstants)
If IsDate(Cell.Value) Then
Cell.NoteText "Date difference is " & Abs(Cell.Value - Date) & "
days."
End If
Next
ExitThis:
End Sub
 
Back
Top