Excel Line graph not displaying all data

Anonymous
2016-08-22T14:51:15+00:00

I have a line graph with the following Data selected:

Apr-16 87.50 95.24 93.33 100.00
May-16 83.33 96.88 96.43 81.25
Jun-16 87.50 96.77 90.00 96.43
Jul-16 89.47 94.44 95.24 80.00
Aug-16 83.33 100.00 87.50 75.00

For some reason the August Data is not being displayed in the chart.

Any ideas what I can do in order to get the August data to appear in the chart.  Hovering over one of the lines in the chart displayed the August data. No matter how many months are added beyond Jul, only the Apr-Jul data is displayed in the chart.

Thanks,

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Anonymous
    2016-08-22T15:11:25+00:00

    Select your data table, assume that below is your chart data table:

    Now got to, "Insert > Chart > Line Chart > Line with Markers" as shown in below:

    Now go to, "Design > Quick Layout > Layout 5" as shown in below:

    You will get your chart as above.

    12 people found this answer helpful.
    0 comments No comments
  2. Anonymous
    2016-08-22T15:33:18+00:00

    Thanks for the response....

    It appears as if the grid in the chart area has been pre-defined to have 4 columns; for example if the only data selected is for Apr, there are three blanks rows displayed in the chart area.  I think what I need to figure out is how to modify the number of rows in the chart area so that it is not predefined to be four...

    ...

    The suggested solution did not impact the display.  Note that the data selected and the type of the chart have already been defined as described. The correct cells are selected as seen:

     The problem is that not all of the data is being displayed.

    The data selected is set in VBA:

    Private Sub AddDepartureReliabilityToSpreadsheet()

        Dim graphX As Integer

        Dim foundSlot As Boolean

        Dim rStr As String

        Dim chartData As Range

        Dim theChart As Chart

        Dim dateStr As String

        foundSlot = False

        With ActiveWorkbook.Sheets("Departure Reliability")

            .ChartObjects("DepartureReliability").Activate

            'ActiveChart.SeriesCollection.NewSeries

            ActiveChart.SeriesCollection(1).Name = "9001"

            ActiveChart.SeriesCollection(2).Name = "9355"

            ActiveChart.SeriesCollection(3).Name = "9358"

            ActiveChart.SeriesCollection(4).Name = "9506"

            'Find the first available month slot

            For graphX = 25 To 36

                If .Cells(graphX, 3).Value = "" Then

                    .Cells(graphX, 3).Value = nowMonthStr & "-" & nowYear

                    'Real

                    .Cells(graphX, 4).Value = reliabilityMonthlyArray(0)

                    .Cells(graphX, 5).Value = reliabilityMonthlyArray(1)

                    .Cells(graphX, 6).Value = reliabilityMonthlyArray(2)

                    .Cells(graphX, 7).Value = reliabilityMonthlyArray(3)

                    'Debug

                    '.Cells(graphX, 4).Value = hoursArray(0) + 100 + graphX

                    '.Cells(graphX, 5).Value = hoursArray(1) + 100 + graphX

                    '.Cells(graphX, 6).Value = hoursArray(2) + 100 + graphX

                    '.Cells(graphX, 7).Value = hoursArray(3) + 100 + graphX

                    '.Cells(graphX, 8).Value = "360"

                    ActiveChart.SeriesCollection(1).XValues = .Range("C25:C" & graphX)

                    ActiveChart.SeriesCollection(1).Values = .Range("D25:D" & graphX)

                    ActiveChart.SeriesCollection(2).XValues = .Range("C25:C" & graphX)

                    ActiveChart.SeriesCollection(2).Values = .Range("E25:E" & graphX)

                    ActiveChart.SeriesCollection(3).XValues = .Range("C25:C" & graphX)

                    ActiveChart.SeriesCollection(3).Values = .Range("F25:F" & graphX)

                    ActiveChart.SeriesCollection(4).XValues = .Range("C25:C" & graphX)

                    ActiveChart.SeriesCollection(4).Values = .Range("G25:G" & graphX)

                    foundSlot = True

                    Exit For

                End If

            Next graphX

            'If no available slots, then current month goes in slot 12 (row 36) and the others are rotated up

            'Only the most recent 12 months are displayed

            If Not foundSlot Then

                .Range("C25:G25").Delete (xlShiftUp)

                .Cells(36, 3).Value = nowMonthStr & "-" & nowYear

                'Real

                .Cells(36, 4).Value = reliabilityMonthlyArray(0)

                .Cells(36, 5).Value = reliabilityMonthlyArray(1)

                .Cells(36, 6).Value = reliabilityMonthlyArray(2)

                .Cells(36, 7).Value = reliabilityMonthlyArray(3)

                'Debug

                '.Cells(36, 4).Value = 260

                '.Cells(36, 5).Value = 280

                '.Cells(36, 6).Value = 300

                '.Cells(36, 7).Value = 320

                ActiveChart.SeriesCollection(1).XValues = .Range("C25:C36")

                ActiveChart.SeriesCollection(1).Values = .Range("D25:D36")

                ActiveChart.SeriesCollection(2).XValues = .Range("C25:C36")

                ActiveChart.SeriesCollection(2).Values = .Range("E25:E36")

                ActiveChart.SeriesCollection(3).XValues = .Range("C25:C36")

                ActiveChart.SeriesCollection(3).Values = .Range("F25:F36")

                ActiveChart.SeriesCollection(4).XValues = .Range("C25:C36")

                ActiveChart.SeriesCollection(4).Values = .Range("G25:G36")

            End If

        End With

    End Sub

    0 comments No comments
  3. Anonymous
    2016-08-22T16:50:27+00:00

    Howdy:

    Although I still do not know what it was about the generation of this table that caused this problem, I got around it by copying and modifying a different table which was working correctly.

    If someone could point out how to control the number of columns that appear in the tabular portion at the bottom of the chart, I would be grateful.

    Thanks Piaaron for responding.

    3 people found this answer helpful.
    0 comments No comments