+ Reply to Thread
Results 1 to 2 of 2

Need help to set Chart to select data that doesnt have a fixed column position.

  1. #1
    Registered User
    Join Date
    04-05-2012
    Location
    Malaysia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Need help to set Chart to select data that doesnt have a fixed column position.

    hye everyone,

    I am creating a chart that pulls data from different columns. Usually the no. of columns dont change but when they do, the chart messes up.

    Does anyone know a way to setup the chart in a way that it selects data in the whole column range based on the top header "name" instead of hard wired to seek e.g $c$1 all the time?

  2. #2
    Registered User
    Join Date
    04-05-2012
    Location
    Malaysia
    MS-Off Ver
    Excel 2007
    Posts
    88

    Re: Need help to set Chart to select data that doesnt have a fixed column position.

    To elaborate.. referring to the code below, I'd like the chart to search for the header of the column instead of the column address. So it changes from

    ActiveChart.SeriesCollection(1).XValues = "='Sheet1'!$A$5:$A$23" to something like
    ActiveChart.SeriesCollection(1).XValues = = Sheet1! "Total Sales"


    Please Login or Register  to view this content.
    Please help.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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