اذهب الي المحتوي
أوفيسنا

ممكن تعديل في كود البحث هذا


hoodahooda

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

Private Sub find_name_Change()
  Dim ct As String * 1
  Dim ss As String * 1

  'On Error Resume Next

  ct = """"
  ss = "*"

  Me.find_name.Tag = Me.find_name.Text
  Me.RecordSource = "SELECT * FROM NEMAS WHERE NEMAS.names LIKE " & ct & ss & (Nz(Me.find_name.Tag)) & ss & ct & ""

  If Me.RecordsetClone.RecordCount = 0 Then
    Me.ÊÝÕíá.Visible = False
    Me.RecordSource = ""
  Else
    Me.ÊÝÕíá.Visible = True
  End If

  Me.find_name = Me.find_name.Tag
  Me.find_name.SetFocus
  SendKeys "{f2}"

End Sub

اريد التعديل في كود البحث هذا بحيث عند كتابة حرف الميم مثلا يظهر الاسماء التي تبدا بحرف الميم وليس الاسماء الذي يوجد فيها حرف الميم

رابط هذا التعليق
شارك

جرب التعديل التالي :

Private Sub find_name_Change()
  Dim ct As String * 1
  Dim ss As String * 1

  'On Error Resume Next

  ct = """"
  ss = "*"

  Me.find_name.Tag = Me.find_name.Text
Me.RecordSource = "SELECT * FROM NEMAS WHERE NEMAS.names LIKE "(Nz(Me.find_name.Tag)) & ss & ct & ""

  If Me.RecordsetClone.RecordCount = 0 Then
    Me.تفصيل.Visible = False
    Me.RecordSource = ""
  Else
    Me.تفصيل.Visible = True
  End If

  Me.find_name = Me.find_name.Tag
  Me.find_name.SetFocus
  SendKeys "{f2}"

End Sub

رابط هذا التعليق
شارك

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