أخي العزيز
عندك حق
الأمر DisplayFormat يعمل فقط مع الكود ولايعمل مع الدوال المخلقة !!!
لاأدري لماذا
ما رأيك في إدخال الشروط (التنسيق الشرطي) في الكود
وبذلك حتي 2003 يستطيع التعامل معها
مثلا يمكنك استبدال الدالة الحالية
Function Compte_Couleurs(cell_range As Range, color_cell_index) As Integer
Dim rCell As Range
Dim cell_count As Integer
cell_count = 0
For Each rCell In cell_range
If rCell.Interior.ColorIndex = color_cell_index Then
cell_count = cell_count + 1
End If
Next rCell
Application.Volatile
Compte_Couleurs = cell_count
End Function
بالدالة التالية
Function new_col_Ind(rg As Range) As Integer
Dim x As Integer, y As Integer, cl As Range
x = 0
For Each cl In rg
y = WorksheetFunction.CountIf([A:A], cl) + WorksheetFunction.CountIf([N:W], cl)
If y = 4 Then x = x + 1
Next
Application.Volatile
new_col_Ind = x
End Function
مرفق الملف بعد التعديل
جرب وأخبرني
CA E70 SEP BID CLOSER_2.rar