Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Set the size of a chart object

Hi,

I want to set the width of an chart (with legend inside) to 3600 pixels.
I try to set it with

Worksheets(1).ChartObjects(1).Width = 3600

The problem is: When I do the Export function afterwards to save the
chart to a PNG file, the file width is 4800 pixels!


Can anyone see the error? How can I export the chart in the size I want
it to?

Thanks, Thomas
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 214
Default Set the size of a chart object

Hi Thomas;
The unit used by Excel is the point.
3600 points in pixels = 3600 * 4/3 = 4800
MP

"Thomas Wieser" <wernze.nospam@gmx_net a écrit dans le message de
y.telekom.at...
Hi,

I want to set the width of an chart (with legend inside) to 3600 pixels.
I try to set it with

Worksheets(1).ChartObjects(1).Width = 3600

The problem is: When I do the Export function afterwards to save the
chart to a PNG file, the file width is 4800 pixels!


Can anyone see the error? How can I export the chart in the size I want
it to?

Thanks, Thomas



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 214
Default Set the size of a chart object

Hi Thomas;
If you want 3600 pixels:
3600 * 3/4 =2700 points
Worksheets(1).ChartObjects(1).Width = 2700
Mp

"Thomas Wieser" <wernze.nospam@gmx_net a écrit dans le message de
y.telekom.at...
Hi,

I want to set the width of an chart (with legend inside) to 3600 pixels.
I try to set it with

Worksheets(1).ChartObjects(1).Width = 3600

The problem is: When I do the Export function afterwards to save the
chart to a PNG file, the file width is 4800 pixels!


Can anyone see the error? How can I export the chart in the size I want
it to?

Thanks, Thomas



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Set the size of a chart object

Hi Michel,

I see, thanks. Yes, I found out yesterday evening after my posting that
the factor must have to be 1.3 periodically - 4/3, as you mentioned.

Now I am sure - thank you!


Greetings from Austria, Thomas


Michel Pierron schrieb:
Hi Thomas;
If you want 3600 pixels:
3600 * 3/4 =2700 points
Worksheets(1).ChartObjects(1).Width = 2700
Mp

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
How do i export a pivot chart as a static chart object? James Charts and Charting in Excel 2 November 11th 08 10:05 PM
Dynamic Chart Object Dimri Excel Discussion (Misc queries) 1 September 19th 06 03:07 PM
Calendar - change of a size of this object Drahos Excel Worksheet Functions 1 February 14th 06 06:01 PM
size of embedded object Amy Wang Excel Discussion (Misc queries) 0 December 9th 05 10:15 PM
is object chart? Mark[_17_] Excel Programming 2 September 30th 03 08:56 PM


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