Results 1 to 8 of 8
  1. #1
    timaldo8 is offline Novice
    Windows 10 Office 365
    Join Date
    Jun 2023
    Posts
    2

    Find as you type field causing error

    I use a find as you type field which uses a row source with entries. The issue is that there is blank entry at the top of the dropdown which is causing an issue. The combo box should show the source list, ie the first entry being "Title" but is blank. This is causing an error when you open the form. . How do I remove this blank entry so that the list shows correctly. Any help I would be grateful. Thanks

  2. #2
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    5,009
    Nothing attached?
    Exclude blank rows from the source.
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  3. #3
    timaldo8 is offline Novice
    Windows 10 Office 365
    Join Date
    Jun 2023
    Posts
    2
    This is the row source entries..i can't work out why the first entry doesnt appear first in the box, which is causing the issue.

    "Title";"Title";111;"[Title]";"10";"FirstName";"FirstName";109;"[FirstName]";"10";"LastName";"LastName";109;"[LastName]";"10";"Address1";"Address1";109;"[Address1]";"10";"Address2";"Address2";109;"[Address2]";"10";"Town";"Town";109;"[Town]";"10";"Postcode";"Postcode";109;"[Postcode]";"10";"NINO";"NINO";109;"[NINO]";"10";"DOB";"DOB";109;"[DOB]";"8";"Mobile";"Mobile";109;"[Mobile]";"10";"Email";"Email";109;"[Email]";"12";"Lead Date";"Lead Date";109;"[Lead Date]";"8";"Lead Type";"Lead Type";111;"[Lead Type]";"10";"Source";"Source";111;"[Source]";"10";"Lead Outcome";"Lead Outcome";111;"[Lead Outcome]";"10";"Appt Date";"Appt Date";109;"[Appt Date]";"8";"ClientStatus";"ClientStatus";111;"[ClientStatus]";"10";"Review Date";"Last Appt Date";109;"[Review Date]";"8";"Apptime";"Time";109;"[Apptime]";"8";"ApptType";"Appointment Type";111;"[ApptType]";"10";"Text94";"Text94";109;"[AgreementDate]";"8";"Employment Status";"Employment Status";111;"[Employment Status]";"10";"AgreementDate";"Agreement Date";109;"[AgreementDate]";"8";"Notes";"Notes";109;"[ReviewNotes]";"12";"RevByDt";"Next Review Date";109;"[RevByDt]";"8";"RevDueDt";"Start Review Date";109;"[RevDueDt]";"8";"RevCompDt";"Last Review Date";109;"[RevCompDt]";"8";"HomeTel";"HomeTel";109;"[HomeTel]";"10";"Report_Due Date";"Report_Due Date";109;"[Report_Due Date]";"8";"Client Segment";"Service Level";111;"[Service Level]";"10";"RiskProfile";"RiskProfile";111;"[RiskProfile]";"10";"Client Category";"Client Category";111;"[Client Category]";"10";"ClientNotes";"ClientNotes";109;"[ClientNotes]";"12";"lookup_clientname";"Referred By";111;"[Lookup_lookup_clientname].[FullName]";"4";"Lump sum withdrawals";"Lump sum withdrawals";109;"[Lump sum withdrawals]";"5";"Text379";"Text379";109;"[Lump sum withdrawals]";"5"

  4. #4
    davegri's Avatar
    davegri is offline Excess Access
    Windows 11 Access 2019
    Join Date
    May 2012
    Location
    Denver
    Posts
    3,423
    I don't get a blank, but the rowsource makes no sense. Duplicate rows appear time after time.

  5. #5
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    5,009
    Quote Originally Posted by timaldo8 View Post
    This is the row source entries..i can't work out why the first entry doesnt appear first in the box, which is causing the issue.

    "Title";"Title";111;"[Title]";"10";"FirstName";"FirstName";109;"[FirstName]";"10";"LastName";"LastName";109;"[LastName]";"10";"Address1";"Address1";109;"[Address1]";"10";"Address2";"Address2";109;"[Address2]";"10";"Town";"Town";109;"[Town]";"10";"Postcode";"Postcode";109;"[Postcode]";"10";"NINO";"NINO";109;"[NINO]";"10";"DOB";"DOB";109;"[DOB]";"8";"Mobile";"Mobile";109;"[Mobile]";"10";"Email";"Email";109;"[Email]";"12";"Lead Date";"Lead Date";109;"[Lead Date]";"8";"Lead Type";"Lead Type";111;"[Lead Type]";"10";"Source";"Source";111;"[Source]";"10";"Lead Outcome";"Lead Outcome";111;"[Lead Outcome]";"10";"Appt Date";"Appt Date";109;"[Appt Date]";"8";"ClientStatus";"ClientStatus";111;"[ClientStatus]";"10";"Review Date";"Last Appt Date";109;"[Review Date]";"8";"Apptime";"Time";109;"[Apptime]";"8";"ApptType";"Appointment Type";111;"[ApptType]";"10";"Text94";"Text94";109;"[AgreementDate]";"8";"Employment Status";"Employment Status";111;"[Employment Status]";"10";"AgreementDate";"Agreement Date";109;"[AgreementDate]";"8";"Notes";"Notes";109;"[ReviewNotes]";"12";"RevByDt";"Next Review Date";109;"[RevByDt]";"8";"RevDueDt";"Start Review Date";109;"[RevDueDt]";"8";"RevCompDt";"Last Review Date";109;"[RevCompDt]";"8";"HomeTel";"HomeTel";109;"[HomeTel]";"10";"Report_Due Date";"Report_Due Date";109;"[Report_Due Date]";"8";"Client Segment";"Service Level";111;"[Service Level]";"10";"RiskProfile";"RiskProfile";111;"[RiskProfile]";"10";"Client Category";"Client Category";111;"[Client Category]";"10";"ClientNotes";"ClientNotes";109;"[ClientNotes]";"12";"lookup_clientname";"Referred By";111;"[Lookup_lookup_clientname].[FullName]";"4";"Lump sum withdrawals";"Lump sum withdrawals";109;"[Lump sum withdrawals]";"5";"Text379";"Text379";109;"[Lump sum withdrawals]";"5"
    What a mess

    Put them all into a table and use that. Easy to change the data as well, as opposed to editng code all the time.

    If you want a proper FAYT combo, check out MajP's classes.
    https://www.access-programmers.co.uk/forums/threads/find-filter-as-you-type-controls-combobox-listbox-form.327863/
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  6. #6
    moke123's Avatar
    moke123 is offline Me.Dirty=True
    Windows 11 Office 365
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,656
    @Dave - Appears that the column count should be 5.

    i can't work out why the first entry doesnt appear first in the box, which is causing the issue.

    This is causing an error when you open the form
    The combo will be blank when you open the form.

    if you want the first entry to be selected when the form opens you have to set it in the onload event.
    .ItemData(0) will select the 1st selection
    .ItemData(1) will select the 2nd selection, etc.


    Code:
    Me.MyCombBoxName = Me.MyComboBoxName.ItemData(0)
    If you show us the whole procedure I'm sure someone can clean it up so the blank combo doesn't error.
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

  7. #7
    davegri's Avatar
    davegri is offline Excess Access
    Windows 11 Access 2019
    Join Date
    May 2012
    Location
    Denver
    Posts
    3,423
    Moke123
    @Dave - Appears that the column count should be 5.
    A deduction worthy of Sherlock Holmes

  8. #8
    moke123's Avatar
    moke123 is offline Me.Dirty=True
    Windows 11 Office 365
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,656
    Quote Originally Posted by davegri View Post
    Moke123


    A deduction worthy of Sherlock Holmes
    Yea, only took me 5 tries
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 5
    Last Post: 11-05-2021, 01:26 PM
  2. file type causing create table code to fail
    By markjkubicki in forum Programming
    Replies: 6
    Last Post: 05-19-2020, 06:07 PM
  3. Data type error - leading zeros format causing problems
    By lmcm1977 in forum Database Design
    Replies: 4
    Last Post: 02-27-2019, 07:52 AM
  4. Replies: 3
    Last Post: 07-21-2014, 09:33 AM
  5. Replies: 4
    Last Post: 06-25-2014, 01:44 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
  •  
Other Forums: Microsoft Office Forums