graphs
The UK's Number 1 for Microsoft Office Training Add this page to your favourites/bookmarksBookmark page
 
View printable version of pagePrintable version
Plus One Google
Customer: Sign in
Delegate: Sign in
Trainer: Log in

Forum home » Delegate support and help forum » Microsoft Excel VBA Training and help » Graphs

Graphs

resolvedResolved · Low Priority · Version 2003

replyReply Tue 16 Dec 2008, 15:53Delegate James said...

James has attended:
Access VBA course
Excel VBA Advanced course

Graphs

Afer making a graph and displaying it on the sheet with the data table. Is there a way of positioning and sizing the graph in vba.

For upcoming training course dates see: Pricing & availability

replyReply Mon 5 Jan 2009, 14:30Trainer Stephen said...

RE: Graphs

Hi James

Thank you for your question

The following code will size and position a chart once it is created

With aChart


.ChartArea.Width = 600
.ChartArea.Height = 400


With .Parent

.Top = Range("K21").Top
.Left = Range("K21").Left


End With


End With

The size of the chart can be altered by using the width and height properties of the chartarea object.

The position of the chart is fixed by using the top and left properties of the chart'sm parent object. This refers to the worksheet that the chart is located in.

Hope this helps

Regards

Stephen

Mon 12 Jan 2009: Automatically marked as resolved.

 

Please browse our web site to find out more about
advanced excel course and other Microsoft training courses.

Excel tip:

Create Equations in Excel 2010

Here's how to create basic mathematical
equations in your Excel 2010 worksheet.

1) On the Ribbon, click the Insert tab
2) In the Symbols group, click the arrow next to Equation
3) Select from the equations and the equation will be inserted in a text box

Or you can create your own equation:

1) Insert and select the text box
2) On the Ribbon, click the Insert tab
3) In the Symbols group, click Equation
4) The Equation Tools Design Ribbon will now be displayed

View all Excel hints and tips


Microsoft Certified Partner Accredited Training Provider: Institute of IT Training Institute of Leadership and Management - Certified Courses Security Seal verified by visa, mastercard securecard