Ms Access | How to prevent duplicate entries of a field on an input form

Поделиться
HTML-код
  • Опубликовано: 23 янв 2025

Комментарии • 17

  • @pertoor
    @pertoor Год назад

    Awesome, thanks!

  • @maryfecorvera7344
    @maryfecorvera7344 4 года назад

    Watching cous Thank you another information again you share to us

  • @sumirekawaii37
    @sumirekawaii37 4 года назад

    Another great vlog tuitorial thank you for sharing po..

  • @MrrChhit
    @MrrChhit 3 года назад +1

    Thank

  • @humayunkhan4012
    @humayunkhan4012 2 года назад

    i applied the same code as shown in the video, but it gives error message e.g syntax error (Missing operator) in query expression

  • @sonnypleesonti8799
    @sonnypleesonti8799 2 года назад +1

    I believed the field in this example is a text type field in the table, my question is what if this field is a number filed what is the correct code to use. Because this code won't work in the table with number field. ?? thanks

    • @abuchoLo
      @abuchoLo 2 года назад

      I was wondring the same as you, until i've found a solution. I change some of the code, like follow:
      Dim NewNo As Integer
      NewNo = DCount("Your Field Name", "Table Name", "Your Field Name =" & Me.Your Field Name.Value & "")
      If NewNo > 0 Then
      MsgBox "The Nmber Has been Already entered", vbInformation, "Duplicate Number"
      Me.Your Field Name.SetFocus
      Me.Undo
      End If
      ------------
      I hope it work with you!

  • @jessicas4640
    @jessicas4640 3 года назад

    Hi there, what if the form is based on a query instead of just one table? The field that I want to prevent duplicates of needs to search a table that is within a query. How would I do that?

    • @KamayoAko
      @KamayoAko  3 года назад +1

      Actually possible. Just change your record source. Like query ilias
      Fullname: then concatenate firstname middlenamen lastname then you can refer that Fullnamen for criteria to lookup the duplicates after updating the lastname or any field you wanted to...

  • @matorwmasen
    @matorwmasen 4 года назад

    Great video as always.
    Was thinking, maybe you can add a delete and update bottoms on the item list form.

  • @basheerpt4089
    @basheerpt4089 4 года назад

    Thanks

  • @spade3993
    @spade3993 2 года назад +1

    Will it work din po ba sa number na data type?

  • @MrDavidGP
    @MrDavidGP 4 года назад

    Great video guide, will the same code still work if i have an item text bix thats alpha numerical (eg. AB12345) been trying to work this out this past week. Thanks 👍

  • @LonelySniper16
    @LonelySniper16 4 года назад

    Harang is life na kapatid....haba haba ah....

    • @KamayoAko
      @KamayoAko  4 года назад

      thank you kapatid kong pasaway.. hehehe...