Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-16-2015, 12:16 PM
KyBob2 KyBob2 is offline Excel Chart Edit Series w/ VBA Windows 7 32bit Excel Chart Edit Series w/ VBA Office 2007
Novice
Excel Chart Edit Series w/ VBA
 
Join Date: Dec 2015
Location: Lexington
Posts: 1
KyBob2 is on a distinguished road
Default Excel Chart Edit Series w/ VBA

I have Charts w/ code to display only non-zero values where the data in an Excel template is populated by Access-to-Excel automation.

As an example, I'm interested in cells RCA!$C$67:$H$79. I can set that as the Chart data range, but can use the Legend Entries (Series) of Series1 and Series6 to display only non-zero entries as a dynamic range.

I have these Named Ranges which are used to edit series values ... Named Range
AAChartVals =OFFSET(RCA!$H$66,1,0,COUNTA(RCA!$H$67:$H$79),1) ... edit series values for Series1=KMI_Temp4.xlsm!ABChartLbls

Set ChartLabels like ... Named Range AAChartLbls =OFFSET(RCA!AAChartVals,0,-5)
... edit series values for Series6 =KMI_Temp4.xlsm!AAChartVals



The above works correctly as long as there is at least an entry in
RCA!$H$67:$H$79. However, no entry in RCA!$H$67:$H$79 makes an error message that there's an invalid formula.

My code will populate any first entry in cell $H$67. I can use an IF statement to see if $H$67 has an entry, and if so, will like to use VBA to set the edit series values to the above descriptions. However if $H$67 has no entry I'd like to set the Chart data range as cells RCA!$C$67:$H$79, which would display Series1 thru Series6 without edited series values.

Anyone with sample code? TIA, Bob
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Generating a chart with dynamic series Officer_Bierschnitt Excel 3 10-15-2015 12:30 AM
chart data series information in slideshow jonen PowerPoint 0 09-24-2014 01:10 AM
Can't Edit Data in Word Chart Dan Reed Word 1 01-26-2012 04:25 PM
Can't select or edit chart data itguy PowerPoint 2 09-19-2010 10:13 AM
Custom animating a line chart by series and category. Gahzi PowerPoint 0 05-19-2009 11:53 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 07:33 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft