And no, I don't mean the colloquialism describing revenge. I'm talking about Payback, the every-so-ironically named internal accounting system now making its fourth appearance (see 1, 2, and 3) on this site. One area of the application we haven't yet covered is the UI experience. And it certainly is an experience.

First, a quick look at the design view of a fairly typical Payback form ...

Doesn't seem too bad; just a few text boxes, a list box, and a timer that fires an event off every three seconds. And heck, even a quick glance looking at the timer event code doesn't seem too bad, either ...

Private Sub ControlTimer_Timer()
  Dim TextEntered As Boolean
  Dim SelectedItem As Boolean
  Dim Index As Integer
  Index = tspCourseInfo.SelectedItem.Index

  'This sub determines when to enable the controls
  SelectedItem = False
  TextEntered = False
  Select Case Index
    Case 1
      If (lstCourseTypes.ListIndex > 0) And _
            (lstCourseTypes.Enabled = True And _
            Len(Trim(txtCourseType.Text)) > 0) Then
        SelectedItem = True
      End If
      If Len(Trim(txtCourseType.Text)) > 0 And _
            Len(Trim(txtCourseTypeName.Text)) > 0 Then
        TextEntered = True
      End If
    Case 2
      If (lstCourses.ListIndex > 0) And _
            (lstCourses.Enabled = True And _
            Len(Trim(txtAbbreviation.Text)) > 0) Then
        SelectedItem = True
      End If
      If Len(Trim(txtCourseName.Text)) > 0 And _
            Len(Trim(txtAbbreviation.Text)) > 0 And _
            Len(Trim(txtMat.Text)) > 0 And _
            Len(Trim(txtCert.Text)) And _
            Len(Trim(txtCreditHours.Text)) > 0 And _
            Len(Trim(txtMaxSize.Text)) > 0 And _
            Len(Trim(txtMinSize.Text)) > 0 Then
        TextEntered = True
      End If
    Case 3
      If blnChangeMade Then TextEntered = True
    Case 4
      If blnPartChangeMade Then TextEntered = True
  End Select

  cmdDelete.Enabled = SelectedItem
  cmdUpdate.Enabled = SelectedItem And TextEntered
  cmdSave.Enabled = TextEntered
  cmdCancel.Enabled = SelectedItem Or TextEntered
End Sub

That is, until you realize the "experience" this gives the users. Instead of behaving like a normal application and responding to UI events (change list item, change text, etc), Payback requires users to wait around for the timer event to fire and change the enabled/disabled and visible/invisible state of other controls.