Programming "Shape" objects (Part 2)
Try this Change event code instead of your current one...
Private Sub Worksheet_Change(ByVal Target As Range)
On Error Resume Next
If Target.Dependents.Address = "$A$1" Then
Shapes("Oval 4").TextFrame.Characters.Text = Range("A1").Value
End If
End Sub
--
Rick (MVP - Excel)
"Robert Crandal" wrote in message
...
Excellent! This works fantastic.
BTW, I tried putting a sum() formula in cell A1 instead of a
constant string. My formula is "=sum(A4:A6)". I noticed that if I
change the values of any cells between A4 to A6 that the sum
does not dynamically display on my shape object. Do you know
why this is happening??
Thank u sooo much!
"Patrick Molloy" wrote in
message ...
use the sheet's change event -- right click the sheet tab and select view
code
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = Range("A1").Address Then
Shapes("Oval 1").Select
Selection.Characters.Text = Target.Value
Target.Select
End If
End Sub
|