Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Phil Hageman
 
Posts: n/a
Default Data Label Value in Formula?

Is it possible to use a data label value in a formula? How would this be done?

Thanks, Phil
  #2   Report Post  
Frank Kabel
 
Posts: n/a
Default

Hi
it is. But maybe give some more details what you're trying to achieve
exactly

--
Regards
Frank Kabel
Frankfurt, Germany
"Phil Hageman" schrieb im
Newsbeitrag ...
Is it possible to use a data label value in a formula? How would this be
done?

Thanks, Phil



  #3   Report Post  
John Mansfield
 
Posts: n/a
Default

Phil,

I may not be understanding your question but would a macro like the example
below do? It extracts the text in the first series data label to an variable
of the integer type and then references that variable in a formula in cell
A1. In this example, the formula would look like "= 6 + your label value +
4". Click on your chart to activate it and then run the macro. If it works
for you, it would need to be modified to your specs:

Sub DataLabelTextToFormula()
Dim Cht As Chart
Dim Val As Integer
Set Cht = ActiveChart
Cht.SeriesCollection(1).ApplyDataLabels Type:=xlDataLabelsShowValue
Val = Cht.SeriesCollection(1).Points(1).DataLabel.Text
Worksheets("Sheet1").Range("A1").Formula = "=6+" & Val & "+4"
End Sub

Other than that, you can always direct reference the data source in your
formula as it is the same source for the data label.

----
Regards,
John Mansfield
http://www.pdbook.com


"Phil Hageman" wrote:

Is it possible to use a data label value in a formula? How would this be done?

Thanks, Phil

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
Limiting Data Obatined By A Graph From A Spread Sheed David Hutton Charts and Charting in Excel 1 December 21st 04 08:11 PM
Charting data ranges that change mikelee101 Charts and Charting in Excel 2 December 17th 04 12:07 AM
Help with pivot charts and data labels [email protected] Charts and Charting in Excel 1 December 15th 04 04:08 PM
Formulas in source data Ken Charts and Charting in Excel 3 December 1st 04 06:43 PM
Extending a Chart Data Series from an Array - Can it be done? Jon Peltier Charts and Charting in Excel 4 November 30th 04 04:30 AM


All times are GMT +1. The time now is 01:58 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"