Simple...Update Text Box in Chart
Hello,
I have a chart in an MS Excel worksheet and I would like to change the value/caption of a textbox( Text Box 20). I have only been able to change the title of the chart with the following: With MyChart.Workbooks(1).Worksheets("Chart").ChartObje cts(1).Chart .HasTitle = True .ChartTitle.Text = "Summary of Report" & date() 'Add Today's Date End With Do I have to reference the chart or do I have to reference the textbox itself? |
Simple...Update Text Box in Chart
Hi,
If the shape is actual embedded in the chart object then something like, ActiveChart.Shapes("Text Box 20").TextFrame.Characters.Text = _ "Hello World" If the shape is just over the chart then replace ActiveChart with Activesheet Cheers Andy Intui_Sol wrote: Hello, I have a chart in an MS Excel worksheet and I would like to change the value/caption of a textbox( Text Box 20). I have only been able to change the title of the chart with the following: With MyChart.Workbooks(1).Worksheets("Chart").ChartObje cts(1).Chart .HasTitle = True .ChartTitle.Text = "Summary of Report" & date() 'Add Today's Date End With Do I have to reference the chart or do I have to reference the textbox itself? -- Andy Pope, Microsoft MVP - Excel http://www.andypope.info |
Simple...Update Text Box in Chart
Thank you very much! I knew I should have mentioned something about
shapes! |
All times are GMT +1. The time now is 10:23 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com