#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 23
Default Data Label size

I am trying to position datalabels on a scatter chart using Bob Bovey's XY
labeller. This puts a label on a chart for each point. Many of the labels
are sloping upwards and consequently I need the bottom left of the label
next to the point concerned. The label position is defined by the Top and
Left and I want to position it by the Bottom Left. Consequently I need to
know the height of the label.
Any ideas how

Thanks

Phil


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,489
Default Data Label size

Hi,

You can not get the Width or Height directly via the object model.
As a work around what you can do is, via code, attempt to move the data
label outside of the chartareas boundaries. As this is not possible the
data labels gets positioned as near to the edge as possible. You can
then use the new left and top position to do some simple maths to work
out the width and height.

Cheers
Andy

Phil Stanton wrote:
I am trying to position datalabels on a scatter chart using Bob Bovey's XY
labeller. This puts a label on a chart for each point. Many of the labels
are sloping upwards and consequently I need the bottom left of the label
next to the point concerned. The label position is defined by the Top and
Left and I want to position it by the Bottom Left. Consequently I need to
know the height of the label.
Any ideas how

Thanks

Phil



--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 23
Default Data Label size

Thanks Andy

That works fine. I now have the bottom left position.

Now I need to get the position (in points???) of the point to which it
refers. Can you help on that one

Thanks again

Phil


"Andy Pope" wrote in message
...
Hi,

You can not get the Width or Height directly via the object model.
As a work around what you can do is, via code, attempt to move the data
label outside of the chartareas boundaries. As this is not possible the
data labels gets positioned as near to the edge as possible. You can then
use the new left and top position to do some simple maths to work out the
width and height.

Cheers
Andy

Phil Stanton wrote:
I am trying to position datalabels on a scatter chart using Bob Bovey's
XY labeller. This puts a label on a chart for each point. Many of the
labels are sloping upwards and consequently I need the bottom left of the
label next to the point concerned. The label position is defined by the
Top and Left and I want to position it by the Bottom Left. Consequently I
need to know the height of the label.
Any ideas how

Thanks

Phil


--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,489
Default Data Label size

Now you have the dimensions of the data label if you center the data label
you can again use a little math to calculate the points position.
So the new Left and Top values plus half the width and height.

Cheers
Andy

--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Phil Stanton" wrote in message
et...
Thanks Andy

That works fine. I now have the bottom left position.

Now I need to get the position (in points???) of the point to which it
refers. Can you help on that one

Thanks again

Phil


"Andy Pope" wrote in message
...
Hi,

You can not get the Width or Height directly via the object model.
As a work around what you can do is, via code, attempt to move the data
label outside of the chartareas boundaries. As this is not possible the
data labels gets positioned as near to the edge as possible. You can then
use the new left and top position to do some simple maths to work out the
width and height.

Cheers
Andy

Phil Stanton wrote:
I am trying to position datalabels on a scatter chart using Bob Bovey's
XY labeller. This puts a label on a chart for each point. Many of the
labels are sloping upwards and consequently I need the bottom left of
the label next to the point concerned. The label position is defined by
the Top and Left and I want to position it by the Bottom Left.
Consequently I need to know the height of the label.
Any ideas how

Thanks

Phil


--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info




  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 23
Default Data Label size

Brilliant

Works a treat

Thanks

Phil

"Andy Pope" wrote in message
...
Now you have the dimensions of the data label if you center the data label
you can again use a little math to calculate the points position.
So the new Left and Top values plus half the width and height.

Cheers
Andy

--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"Phil Stanton" wrote in message
et...
Thanks Andy

That works fine. I now have the bottom left position.

Now I need to get the position (in points???) of the point to which it
refers. Can you help on that one

Thanks again

Phil


"Andy Pope" wrote in message
...
Hi,

You can not get the Width or Height directly via the object model.
As a work around what you can do is, via code, attempt to move the data
label outside of the chartareas boundaries. As this is not possible the
data labels gets positioned as near to the edge as possible. You can
then use the new left and top position to do some simple maths to work
out the width and height.

Cheers
Andy

Phil Stanton wrote:
I am trying to position datalabels on a scatter chart using Bob Bovey's
XY labeller. This puts a label on a chart for each point. Many of the
labels are sloping upwards and consequently I need the bottom left of
the label next to the point concerned. The label position is defined by
the Top and Left and I want to position it by the Bottom Left.
Consequently I need to know the height of the label.
Any ideas how

Thanks

Phil

--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info








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
Label template for Excel in Avery size 8160? Lace Excel Worksheet Functions 3 January 7th 08 04:57 PM
How to rezize data label box in pie charts (label wraps to two lin rolliedogg Charts and Charting in Excel 1 October 18th 06 08:17 PM
Cell size? Or size limit for Text data type? CClem Excel Discussion (Misc queries) 0 April 21st 06 04:09 PM
Vert. axis label is being trimmed by two letters no matter size A little short Charts and Charting in Excel 2 November 22nd 05 01:09 PM
how do I change the size of the y-axis label? Alex Charts and Charting in Excel 1 January 12th 05 09:03 PM


All times are GMT +1. The time now is 02:50 PM.

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

About Us

"It's about Microsoft Excel"