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

خطا في البحث ( مرفق رسالة الخطا )


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

لدى مشكلة في خطا مرفق لكم الخطأ 

 

اتمني من الله ثم من اساتذتنا المساعدة 

 

Private Sub ButtonSerach_Click()
Dim tb1 As Boolean, ib As Boolean
Dim R As Long, RR As Long
Dim C As Integer
Dim MyFind, MySrch, MyVelue
''''''''''''''''''''''
Me.ListFind.Clear
If Len(Trim(Me.TextFind)) = 0 Then Exit Sub
'''''''''''''''''''''
C = Me.BoxFind.ListIndex + 1
tb1 = CBool(Me.CheckFindDate.Value = True)
If tb1 Then
    If Not IsDate(Me.TextFind) Then kh_SetDate Me.TextFind
    MyFind = CDbl(CDate(Me.TextFind))
    
Else
    MyFind = Me.TextFind.Value
End If
'''''''''''''''''''''''
With MyRngdate.Cells(2, Ar(C))
    For R = 1 To ContRow
        If Len(Trim(.Cells(R, 1))) Then
            If tb1 Then MySrch = .Cells(R, 1).Value2 Else MySrch = .Cells(R, 1).Value
            ib = IIf(Me.CheckFind.Value, InStr(1, MySrch, MyFind, vbTextCompare) = 1, InStr(1, MySrch, MyFind, vbTextCompare))
            If ib Then
                MyVelue = .Cells(R, 1).Value
                If IsDate(MyVelue) Then MyVelue = Format(MyVelue, DtF)
                Me.ListFind.AddItem MyVelue
                Me.ListFind.List(RR, 1) = R
                RR = RR + 1
            End If
        End If
    Next
End With

Me.LblFindCount = Me.ListFind.ListCount
If RR = 0 Then MsgBox " لا توجد نتائج لبحثك هذا  ", mBox, "تنبيه"

'''''''''''''''''''''''''
End Sub
 

 

1.jpg.2898f159230e1dd5cc4f7f190fdb3c7b.jpg

2.jpg

تم تعديل بواسطه محمود الحربي
رابط هذا التعليق
شارك

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