اذهب الي المحتوي
أوفيسنا
بحث مخصص من جوجل فى أوفيسنا
Custom Search

الردود الموصى بها

  • تمت الإجابة
قام بنشر

وعليكم السلام ورحمة الله وبركاته

تفضل اخي الكريم

Private Sub N1_BeforeUpdate(Cancel As Integer)
On Error Resume Next
    If Me.NewRecord = True Then
    Dim strWhere As String, strMessage As String
    
    strWhere = "[B] = '" & Me![N1] & "'"
    Me.RecordsetClone.MoveFirst
    Me.RecordsetClone.FindFirst strWhere
    If Me.RecordsetClone.NoMatch = False Then
        strMessage = " الصنف مكرر"
        lResponse = MsgBox(strMessage, vbOKOnly + vbCritical)
            If lResponse = vbOK Then
                Cancel = True
                Me.Undo
                Me.Bookmark = Me.RecordsetClone.Bookmark
            End If
    End If
End If

End Sub

TEST11.rar

تحياتي

  • Like 2
  • Thanks 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

زائر
اضف رد علي هذا الموضوع....

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • تصفح هذا الموضوع مؤخراً   0 اعضاء متواجدين الان

    • لايوجد اعضاء مسجلون يتصفحون هذه الصفحه
×
×
  • اضف...

Important Information