View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
P. Dua-Brown P. Dua-Brown is offline
external usenet poster
 
Posts: 8
Default Determining whether a named textbox on a chart exists

Hi

I'm using Excel 2003 to generate charts using vba.

On the charts I've created I add a few textboxes that I've named:

myChart.Chart.Shapes.AddTextbox(msoTextOrientation Horizontal, 5, 280, 300,
10).Name = "footer"
myChart.Chart.Shapes.AddTextbox(msoTextOrientation Horizontal, 50, 2, 305,
32).Name = "Chart Title"

What I would like to do is create another macro which users can use to
reformat Charts. This involves checking that the named textbox exists (users
may have deleted it) and if it does position it.

I can not figure out how to do this - can anyone point me in the right
direction?

Many thanks

Preeti