Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
pete3589
 
Posts: n/a
Default Axis label that corresponds to cell


I have an interactive graph which graphs data from a set column. This
column changes depending on what is selected on a list selector. I was
wondering if there is a way to label the y axis whatever was in, say
cell AD11.

I was hoping that that this would be something easy that I could write
into the excel chart wizard, like =$AD$11, but it is not. Any help
would be appreciated.


--
pete3589
------------------------------------------------------------------------
pete3589's Profile: http://www.excelforum.com/member.php...o&userid=28402
View this thread: http://www.excelforum.com/showthread...hreadid=483691

  #2   Report Post  
Rowan Drummond
 
Posts: n/a
Default Axis label that corresponds to cell

Assuming the chart is an embeded object on the sheet and is called
"Chart 1" then this will change the Y axis title every time AD11 is changed:

Private Sub Worksheet_Change(ByVal Target As Range)
Dim chrt As ChartObject
Dim axs As AxisTitle
If Target.Address = "$AD$11" Then
Set chrt = Me.ChartObjects("Chart 1")
Set axs = chrt.Chart.Axes(xlValue).AxisTitle
axs.Characters.Text = Target.Value
End If
End Sub

This is worksheet event code. Right click the sheet tab, select View
Code and paste the code in there.

Hope this helps
Rowan

pete3589 wrote:
I have an interactive graph which graphs data from a set column. This
column changes depending on what is selected on a list selector. I was
wondering if there is a way to label the y axis whatever was in, say
cell AD11.

I was hoping that that this would be something easy that I could write
into the excel chart wizard, like =$AD$11, but it is not. Any help
would be appreciated.


  #3   Report Post  
pete3589
 
Posts: n/a
Default Axis label that corresponds to cell


Yes it did. Thank you Rowan


--
pete3589
------------------------------------------------------------------------
pete3589's Profile: http://www.excelforum.com/member.php...o&userid=28402
View this thread: http://www.excelforum.com/showthread...hreadid=483691

  #4   Report Post  
Rowan Drummond
 
Posts: n/a
Default Axis label that corresponds to cell

You're welcome.

pete3589 wrote:
Yes it did. Thank you Rowan


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
copying cell names Al Excel Discussion (Misc queries) 12 August 11th 05 03:01 PM
Link a cell to min & max box for Value (X) axis scale? cwilliams Charts and Charting in Excel 2 June 6th 05 09:19 PM
Format chart axis by inputting data in a cell Mike Charts and Charting in Excel 1 May 30th 05 03:52 PM
Excel graph y axis label cut murreleteer Charts and Charting in Excel 2 January 9th 05 02:22 PM
the dates to label the x axis on the scatter chart won't print waterlady Charts and Charting in Excel 0 November 29th 04 06:44 PM


All times are GMT +1. The time now is 08:44 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"