LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 36
Default chart sheet value (Y) axis scale data report - an example

Hello. No question here, just a procedure for the archive.

Returns value (Y) axis scale data (the max and min scales and major
and minor units) for all charts sheets in active workbook.


Sub ChartSheetScaleReport()
'Return all scales for all chart sheets in active workbook
On Error Resume Next

If ActiveWorkbook.Charts.Count = 0 Then
MyVar = MsgBox("There are no chart sheets in this workbook")
If MyVar = vbOK Then _
Exit Sub
End If

ActiveWorkbook.Worksheets.Add.Name = "ChartSheetScales"
Sheets("ChartSheetScales").Select
Range("A1").Select
ActiveCell.Value = "Workbook Name"
ActiveCell.Offset(0, 1).Value = "Chart Sheet Name"
ActiveCell.Offset(0, 2).Value = "Min Scale"
ActiveCell.Offset(0, 3).Value = "Max Scale"
ActiveCell.Offset(0, 4).Value = "Major Unit"
ActiveCell.Offset(0, 5).Value = "Minor Unit"

Range("A2").Select

For iChart = 1 To ActiveWorkbook.Charts.Count
ActiveCell.Offset(iChart - 1, 0) = ActiveWorkbook.Name
ActiveCell.Offset(iChart - 1, 1) = Charts(iChart).Name
ActiveCell.Offset(iChart - 1, 2) =
Charts(iChart).Axes(xlValue).MinimumScale
ActiveCell.Offset(iChart - 1, 3) =
Charts(iChart).Axes(xlValue).MaximumScale
ActiveCell.Offset(iChart - 1, 4) =
Charts(iChart).Axes(xlValue).MajorUnit
ActiveCell.Offset(iChart - 1, 5) =
Charts(iChart).Axes(xlValue).MinorUnit

Next iChart

Sheets("ChartSheetScales").Select
Columns("A:F").EntireColumn.AutoFit

End Sub



Search criteria:
get chart scales return chart scales get chart sheet scales return
chart sheet scales extract chart
sheet scales return chart maximum scale return chart minimum scale
return major units return minor units
extract chart sheet scale data extract chart sheet scale values
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to force chart axis to same scale Sandusky Excel Discussion (Misc queries) 3 February 18th 09 04:57 AM
How to draw chart: log scale on X axis, natural scale on y axis? Pratap D. chavan Charts and Charting in Excel 1 November 16th 06 08:03 AM
Time scale axis should be available in PivotChart Report. vertblancrouge Charts and Charting in Excel 1 April 11th 05 01:42 AM
Time scale axis should be available in PivotChart Report. vertblancrouge Charts and Charting in Excel 0 April 7th 05 09:43 PM
How do I scale the axis of a chart from external data so that dis. statherdunn Charts and Charting in Excel 1 January 10th 05 05:17 PM


All times are GMT +1. The time now is 12:15 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"