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

مسح المعادلات


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

السادة الخبراء

اريد حذف المعادلات فى نطاق معين وهذا كود اريد تعديلة

Sub Formula()
Dim Cl As Range

Application.ScreenUpdating = False
Application.Calculation = xlCalculationManual

    For Each Cl In Range("AZ1:AZ300")
        If Cl.Value = Formula Then
        Cl.ClearContents
            
        End If
    Next Cl

Application.ScreenUpdating = True
Application.Calculation = xlCalculationAutomatic
End Sub

يعطى خطاء فى هذا السطر   If Cl.Value = Formula Then

جزاكم الله كل خيراً

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

والافضل من ذلك هذا الكود اليسبط

Sub Macro1()
    Range("AZ1:AZ300").SpecialCells(xlCellTypeFormulas, 23).ClearContents
  End Sub

للعمل حسب الماكرو عندك استبدل السطر المذكور بهذا

If Cl.HasFormula Then

 

 

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

1 دقيقه مضت, خالد الشاعر said:

استاذ سليم

شكرا على سرعة المساعدة

جزاك الله كل خيراً

اين الاعجاب

او ان النقر على الزر صعبة أوي (انا امزح):fff:

  • 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