+ Reply to Thread
Results 1 to 3 of 3

Get rid of graphic border

  1. #1
    Registered User
    Join Date
    11-28-2017
    Location
    Araras, Brazil
    MS-Off Ver
    Office for Mac 2011
    Posts
    2

    Get rid of graphic border

    I need to get rid of borders of my graphs, but without appeal to "shapes". To understand my problem easier, here is a part of my code:

    RangeString = "AA5:AB" + CStr(LastRow + 4)
    Set rng = .Range(RangeString)
    'Create a chart
    Set cht = ActiveSheet.ChartObjects.Add(Left:=Worksheets(NewSheet).Range(RefCellPosGraf1).Left, Width:=GraphWidth, Top:=Worksheets(NewSheet).Range(RefCellPosGraf1).Top, Height:=GraphHeight)
    cht.Chart.SetSourceData Source:=rng
    cht.Chart.ChartType = xlPie
    cht.Chart.ChartStyle = Worksheets("Config").Range("B62").Value
    cht.Chart.HasTitle = True
    cht.Chart.PlotVisibleOnly = False
    cht.Chart.ChartTitle.Text = "MdC por segmento"
    cht.Chart.PlotVisibleOnly = False

    Would it be possible to fit in a cht.Chart.Border = False or something like that?

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    2013 / 2016 / 365
    Posts
    7,140

    Re: Get rid of graphic border

    You could still use shapes
    Please Login or Register  to view this content.
    I ask why you are building the chart to begin with. If it is to cover a range of data that is dynamic, there are other ways to accomplish this. You can construct the chart from a table (which is dynamic) or you can link the data to named dynamic ranges.
    http://www.utteraccess.com/wiki/Offs...Dynamic_Ranges
    http://www.utteraccess.com/wiki/Dynamic_Charting
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Registered User
    Join Date
    11-28-2017
    Location
    Araras, Brazil
    MS-Off Ver
    Office for Mac 2011
    Posts
    2

    Re: Get rid of graphic border

    Thanks dflak, your solution worked just fine!
    The range question is due to the fact that this is an old program that I am re-looking. Since then I've learned better ways to handle the issue. And yes, the range is of dynamic data.
    Many thanks again!:

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Format .. Border .. I need a thicker border
    By Trebor777 in forum Excel General
    Replies: 1
    Last Post: 10-26-2016, 09:41 AM
  2. Remove border from legend entry without removing border from pie chart
    By cartman88 in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 08-06-2015, 04:16 AM
  3. [SOLVED] Mysterious additional border to left of rows border?
    By Oppressed1 in forum Excel General
    Replies: 2
    Last Post: 10-10-2012, 03:22 PM
  4. Remove extra border and put all border in last row of generated output
    By cruise.alter in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-05-2012, 01:21 AM
  5. Replies: 1
    Last Post: 03-29-2011, 08:22 AM
  6. Replies: 2
    Last Post: 10-05-2005, 04:05 PM
  7. Replies: 0
    Last Post: 01-12-2005, 10:50 AM

Tags for this Thread

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