اذهب الي المحتوي
أوفيسنا
بحث مخصص من جوجل فى أوفيسنا
Custom Search

دائرة حمراء


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

السلام عليكم ورحمة الله

استخدم الكودين الاتيين

الكود الاول لرسم الدوائر

Sub Crl_Shp()
' دوائر مواد الرسوب
Dim C As Range
Dim MyRng As Range
Dim LR As Long, i As Long, j As Long
Application.ScreenUpdating = False
LR = Range("B" & Rows.Count).End(xlUp).Row
i = 10
Do While i <= LR
Set MyRng = Range(Cells(i, 5), Cells(i, 23))
For Each C In MyRng
If C.Value < Cells(9, C.Column).Value Or C.Value = "غ" Or C.Value = "" Then
Set x = ActiveSheet.Shapes.AddShape(msoShapeOval, C.Left, C.Top, C.Width, C.Height)
x.Fill.Visible = msoFalse
x.Line.ForeColor.SchemeColor = 10
x.Line.Weight = 1.75
End If
Next
i = i + 1
Loop
Application.ScreenUpdating = True
End Sub

الكود الثانى لمسح الدوائر عند اللزوم

Sub RemovShp()
   ' مسح الدوائر
Dim Shp As Shape
For Each Shp In ActiveSheet.Shapes
If Shp.AutoShapeType = msoShapeOval Then Shp.Delete
Next Shp
End Sub

 

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

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