The following code triggers upon any change in the textbox "MinusICells", including deleting the existing value. I'm trying to get the code to trigger only when the value is actually changed/updated.
I've tried _AfterUpdate and _ItemChanged, but neither worked. Does anyone know the correct syntax to get this code to trigger only when the MinusICells textbox value has been updated to a new/different value?
Thanks,
Paul Hudgens
Denver
Code:
Private Sub MinusICells_Change()
Dim ic As Integer, iCount As Integer, jCount As Integer, iMCells As Integer, iPCells As Integer
If Not IsNumeric(LGRData.MinusICells) Then Exit Sub
Me.ComboBox1.Clear
iMCells = CInt(lgrdata.MinusICells)
iPCells = CInt(lgrdata.PlusICells)
iCount = iMCells + iPCells + 1
For ic = 1 To iCount
Me.ComboBox1.AddItem "Default"
Next ic
End Sub
I've tried _AfterUpdate and _ItemChanged, but neither worked. Does anyone know the correct syntax to get this code to trigger only when the MinusICells textbox value has been updated to a new/different value?
Thanks,
Paul Hudgens
Denver