Consulting

Results 1 to 7 of 7

Thread: Check the recordcount of a combo Box If 0 set additions to false

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Check the recordcount of a combo Box If 0 set additions to false

    Hello, I have a combobox (cbo1) that its row source is a sql that allows me to select data and for the next record the data selected previousl wont show in the combo box. This happens for each record until there isn't any data to select in the combo box. I want to set additions to false when there isn't any data in the combo. I tried:

    Private Sub cboComponent_Dirty(Cancel As Integer)
        If cboComponent.RecordsetClone.RecordCount > 1 Then
            Cancel = True
        Else
            Me.AllowAdditions = False
        End If
    End Sub
    Last edited by Aussiebear; 03-12-2025 at 09:23 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •