ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   New Users to Excel (https://www.excelbanter.com/new-users-excel/)
-   -   How can you draw a shape when the values change each time?? (https://www.excelbanter.com/new-users-excel/83496-how-can-you-draw-shape-when-values-change-each-time.html)

man57

How can you draw a shape when the values change each time??
 


Ardus Petus

How can you draw a shape when the values change each time??
 
See example with worksheet Change event proc: http://cjoint.com/?erkFfzkxwN

HTH
--
AP

'--------------
Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect( _
Target, _
Union( _
Range("Center_X"), _
Range("Center_Y"), _
Range("Radius") _
) _
) Is Nothing Then Exit Sub
With Me.Shapes("Circle1")
.Top = Range("Center_Y").Value - Range("Radius").Value
.Left = Range("Center_X").Value - Range("Radius").Value
.Height = 2 * Range("Radius").Value
.Width = .Height
End With
End Sub
'---------------
"man57" a écrit dans le message de
...





All times are GMT +1. The time now is 01:43 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com