dropdown list select event.

  • Thread starter Thread starter PBcorn
  • Start date Start date
P

PBcorn

I have a custom dropdown data validation, but need to capture the point at
which the selection is made by the user in order to measure the time between
this and a comanndbutton press. Any ideas?
 
in a module add a PUBLIC variable as DOUBLE
set the value of this using the sheet's change event to trap the value
changing
use the cutton's code to get the elapsed time...
here's a sample sheet code (rigth-click the sheet tab & select view code

Option Explicit
Public t As Double
Private Sub Worksheet_Change(ByVal Target As Range)
t = Timer
End Sub
Private Sub CommandButton1_Click()
MsgBox Timer - t
End Sub

this sets the time for ANY changes...so you'll need to test if the cell
that's changed is the cell containing the validation etc etc...but this is
just an exampel
 
Back
Top