+ Reply to Thread
Results 1 to 4 of 4

PLEASE HELP! Problems with ActiveChart.PlotBy = xlRows

  1. #1
    Registered User
    Join Date
    12-12-2014
    Location
    Brazil
    MS-Off Ver
    2010
    Posts
    2

    Question PLEASE HELP! Problems with ActiveChart.PlotBy = xlRows

    Hi im am a begginer programmer and this is my first time using Excel VBA. I am using macors to generate a graph based on an average grade that i have calculated in another macro. I have to check a series of columns to see if any include the average data and if so locate the value that needs to be added to the graph. I was able to produce the graph, however the values are presented in different series and i cannot have that because i need to produce a trendline. When i run the code the error is in the "ActiveChart.PlotBy = xlRows" and it says that " The specified dimension is not valid for the current chart type.". However if i perform the operation manually it works perfectly. PLEASE HELPP! This is my code:

    Please Login or Register  to view this content.
    Last edited by Ajardim; 12-12-2014 at 01:37 PM.

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,864

    Re: PLEASE HELP! Problems with ActiveChart.PlotBy = xlRows

    1) please edit your post and use code tags - see how-to in forum rules.

    2) as you do not show a multi-column and multi-row range as data source there is no chance to use plotBy property. Moreover, your series are just 1 point each, so you cannot use trendlines. To use trendlines make your series contain more than one data point.
    Best Regards,

    Kaper

  3. #3
    Registered User
    Join Date
    12-12-2014
    Location
    Brazil
    MS-Off Ver
    2010
    Posts
    2

    Re: PLEASE HELP! Problems with ActiveChart.PlotBy = xlRows

    Thank you very much for your reply! I did not know that the plotBy property needed multi-row and mulit-column range as a data source. You said that my series contain only one point each and that is exactly my problem, i was using plotBy to make my points become of the same series and then i would be able to add a trendline. How can i make my points of different series be of the same series withought using plotby?

  4. #4
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,864

    Re: PLEASE HELP! Problems with ActiveChart.PlotBy = xlRows

    May be - try to collect all points and then plot them as one serie. for instance such main loop (not tested, because you pattched no sample workbook:
    Please Login or Register  to view this content.

+ 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. ActiveChart.Name not working
    By rtcwlomax in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-03-2011, 12:45 PM
  2. I am losing my ActiveChart.Name
    By mattdick in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 05-01-2009, 10:01 AM
  3. ActiveChart.SeriesCollection(2) problem
    By manuweb_21 in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 02-20-2009, 10:54 AM
  4. ActiveChart.Location help
    By dvent in forum Excel General
    Replies: 0
    Last Post: 11-16-2007, 05:25 AM
  5. Why does Excel automatically choose the PlotBy method
    By roybrew@att.net in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 02-16-2005, 09:56 AM

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