الشلام عليكم ورحمة الله وبركاته
الاساتذة المشرفين والاعضاء الافاضل مرفق كود ارجوا التكرم بشرح المعلم عليها بالاحمر على ماذا تشير :
Private Sub Worksheet_Change(ByVal Target As Range)
Dim MyRows As Integer, MyCount As Integer
MyRows = Range("kh_test").Rows.Count
MyCount = Application.CountA([kh_test]) + 1
On Error GoTo 1
If Target.Address = Range("kh_test").Cells(MyRows - 2, 1).Address Then
If MyRows = MyCount Then
Target.Resize(1, 4).Interior.ColorIndex = xlNone
Range("kh_test").Cells(MyRows - 1, 1).EntireRow.Insert
Target(2, 1).Resize(1, 4).Interior.ColorIndex = 36
End If
End If
1 End Sub
تحياتي لكم
تم رفع الملف الخاص بالكود
http://arb-up.com/sg...______.rar.html