+ Reply to Thread
Results 1 to 5 of 5

Excel Legends. How can I show the line type on my legends?

  1. #1
    Registered User
    Join Date
    09-16-2020
    Location
    Toronto, Canada
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO 64 bit
    Posts
    1

    Excel Legends. How can I show the line type on my legends?

    I am using Microsoft Excel for Microsoft 365 MSO 64-bit.

  2. #2
    Forum Expert JLGWhiz's Avatar
    Join Date
    02-20-2011
    Location
    Florida, USA
    MS-Off Ver
    Windows 10, Excel 2013
    Posts
    2,070

    Re: Excel Legends. How can I show the line type on my legends?

    Quote Originally Posted by mrup096 View Post
    I am using Microsoft Excel for Microsoft 365 MSO 64-bit.
    I don't see any reference to line types in the properties or methods. Here is the spec sheet link:
    https://docs.microsoft.com/en-us/off...nd%28object%29

    However, I find that it can be manually set in xl2013 by right click in the chart area, the click Format Chart Area and work from the menus that are provided. Still looking for vba method.
    Last edited by JLGWhiz; 09-20-2020 at 03:40 PM.
    Any code provided by me should be tested on a copy or a mock up of your original data before applying it to the original. Some events in VBA cannot be reversed with the undo facility in Excel. If your original post is satisfied, please mark the thread as "Solved". To upload a file, see the banner at top of this page.
    Just when I think I am smart, I learn something new!

  3. #3
    Forum Expert JLGWhiz's Avatar
    Join Date
    02-20-2011
    Location
    Florida, USA
    MS-Off Ver
    Windows 10, Excel 2013
    Posts
    2,070

    Re: Excel Legends. How can I show the line type on my legends?

    After some experimenting, this worked.

    Please Login or Register  to view this content.
    Line styles are the same syntax for all objects, so you can eaily change them, eg. xlContinuous and xlDouble, etc.
    Weight will determine the thickness of the line. Weight = xlThin

    As I said previously, these can be set manually.
    Last edited by JLGWhiz; 09-20-2020 at 04:24 PM.

  4. #4
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,434

    Re: Excel Legends. How can I show the line type on my legends?

    This is for the legend entries, rather than the border around the legend.

    Please Login or Register  to view this content.
    Cheers
    Andy
    www.andypope.info

  5. #5
    Forum Expert JLGWhiz's Avatar
    Join Date
    02-20-2011
    Location
    Florida, USA
    MS-Off Ver
    Windows 10, Excel 2013
    Posts
    2,070

    Re: Excel Legends. How can I show the line type on my legends?

    The OP was not clear about whether they wanted vba or just a manual procedure. But in vba it looks to me like the ChartFormat object is the key to lines and border formatting. LegendFormat and LineFormat are both part of ChartFormat. Object Browser is not clear on the legend.format but the code works, so that is what matters.
    Last edited by JLGWhiz; 09-21-2020 at 10:07 AM.

+ 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. Excel VBA to hide zero/blank legends from DYNAMIC CHARTs
    By mchilapur in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-30-2019, 12:41 AM
  2. Excel 2007 Legends
    By Beaumonts in forum Excel Charting & Pivots
    Replies: 6
    Last Post: 10-23-2013, 04:49 AM
  3. Excel 2007 Graphing with Legends
    By TribalLoser in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 09-09-2013, 03:53 AM
  4. Replies: 3
    Last Post: 08-20-2006, 03:45 PM
  5. Sub/Superscripting should work in Excel Legends/Axis Labels
    By miwillia in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 07-18-2006, 12:40 AM
  6. [SOLVED] Excel Chart Legends need alignment option (rotate 90-180-270 deg)
    By ron ebelhar in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 08-29-2005, 02:05 PM
  7. legends in excel
    By lilpunkk12 in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 08-04-2005, 10:05 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