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

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

قام بنشر

هذا الكود يعمل على العمود B

حاول تطبيقه على الاعمدة الاخرى

Option Explicit

Sub test()
Dim lr, f
f = "=IF(ISERROR" & "(MATCH($A3,OFFSET" & "(INDIRECT(ADDRESS" & "(1,1,,,B$2)),,,1000,1),0))" & "," & """لم يدخل""" & "," & """دخل""" & ")"
lr = Cells(Rows.Count, 1).End(xlUp).Row
Range("b3:b" & lr).Formula = f

End Sub

ربط جداول من اوراق اخرى.xlsm

  • Like 1
  • أفضل إجابة
قام بنشر

ان لم تستطيع اليك هذا

Sub test()
Dim lr, f, f2, f3, f4, f5, f6
f = "=IF(ISERROR" & "(MATCH($A3,OFFSET" & "(INDIRECT(ADDRESS" & "(1,1,,,B$2)),,,1000,1),0))" & "," & """لم يدخل""" & "," & """دخل""" & ")"
f2 = "=IF(ISERROR" & "(MATCH($A3,OFFSET" & "(INDIRECT(ADDRESS" & "(1,1,,,C$2)),,,1000,1),0))" & "," & """لم يدخل""" & "," & """دخل""" & ")"
f3 = "=IF(ISERROR" & "(MATCH($A3,OFFSET" & "(INDIRECT(ADDRESS" & "(1,1,,,D$2)),,,1000,1),0))" & "," & """لم يدخل""" & "," & """دخل""" & ")"
f4 = "=IF(B3=""دخل"",INDIRECT(ADDRESS(MATCH($A3,OFFSET(INDIRECT(ADDRESS(1,1,,,F$2)),,,1000,1),0),2,,,F$2)),"""")"
f5 = "=IF(C3=""دخل"",INDIRECT(ADDRESS(MATCH($A3,OFFSET(INDIRECT(ADDRESS(1,1,,,G$2)),,,1000,1),0),2,,,F$2)),"""")"
f6 = "=IF(D3=""دخل"",INDIRECT(ADDRESS(MATCH($A3,OFFSET(INDIRECT(ADDRESS(1,1,,,H$2)),,,1000,1),0),2,,,F$2)),"""")"

lr = Cells(Rows.Count, 1).End(xlUp).Row
Range("b3:b" & lr).Formula = f
Range("C3:C" & lr).Formula = f2
Range("D3:D" & lr).Formula = f3
Range("f3:f" & lr).Formula = f4
Range("g3:g" & lr).Formula = f5
Range("h3:h" & lr).Formula = f6
Range("b3:h" & lr).Value = Range("b3:h" & lr).Value
End Sub

 

  • Like 1
قام بنشر

الاخ حسين مأمون

زادك الله علما وجزاك خيرا

لم انتبة الى الفقرة الاخيرة      Range("b3:h" & lr).Value = Range("b3:h" & lr).Value

وهو المطلوب

  • Like 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