Results 1 to 3 of 3

ReSizing Chart to fit Width and Columns

Threaded View

  1. #1
    Registered User
    Join Date
    03-13-2009
    Location
    London, England
    MS-Off Ver
    Excel 2016
    Posts
    98

    ReSizing Chart to fit Width and Columns

    Hi,

    I am trying to Copy a Chart from 1 sheet, Paste it into another in a specific location based on Columns and ROWS.

    I have managed to get the code to copy and paste to a particular cell, however cannot re-size it to fit the required Rows and Columns.

    Steps involved are:

    1)Copy a Named Chart based on If Function in Sheet "Heart Rate"
    2)Paste into Sheet Report and Rename the Chart to "BMI"
    3)Re-size the chart to fit between Cells B3:I15 (Cannot get this to work)



    Sub Macro6()
    '
    ' Macro6 Macro
    '

    '

    If Worksheets("Heart Rate").Range("O3") = 1 Then

    Worksheets("Heart Rate").ChartObjects("Chart 2").Activate
    ActiveChart.ChartArea.Copy
    Sheets("Report").Select
    Range("B3").Select
    ActiveSheet.Paste


    ActiveChart.Parent.Name = "BMI"




    Else

    Worksheets("Heart Rate").ChartObjects("Chart 3").Activate
    ActiveChart.ChartArea.Copy
    Sheets("Report").Select
    Range("B3").Select
    ActiveSheet.Paste

    ActiveChart.Parent.Name = "BMI"



    End If

    End Sub
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Resizing and Moving a chart
    By sokeefe14 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-29-2015, 10:11 AM
  2. auto column width resizing
    By misterpogiako in forum Excel General
    Replies: 4
    Last Post: 02-13-2014, 01:42 PM
  3. Excel 2007 : Resizing Chart Boxes
    By Shidoran in forum Excel General
    Replies: 2
    Last Post: 09-13-2010, 07:38 PM
  4. Exporting Word Chart to Excel (Resizing Chart)
    By bg18461 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-12-2008, 11:49 AM
  5. Resizing chart because of refreshing Chart Data through a query
    By jayb in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 08-10-2006, 11:25 AM
  6. [SOLVED] Set Column Width Based On Total Width Of Other Columns
    By rayneraingoaway in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-28-2006, 06:10 PM
  7. [SOLVED] Chart resizing handles
    By Sarge in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 01-30-2006, 05:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1