I have very little knowledge of editing Visual Basic and I'm a little stuck on something: somewhere within this code (below) I am getting a chart area border showing on my graphs - but I don't want a border and cant find the coding to remove it. (I previously had Excel 03 and found this easier as I would record a macro and look at the coding to see where I needed to edit, but I can't seem to do that in 07 
Could someone point out how I could remove the border please (do I need to attach a sample workbook for this?)
Many thanks in advance.
'grab name for new chart and title
aName = ws.Cells(iRow, 1)
'delete old chart
Sheets(aName).Delete
'make new chart
Charts.Add
ActiveSheet.Move after:=Sheets(ActiveWorkbook.Sheets.Count)
ActiveChart.ChartType = xlBarClustered
ActiveChart.SetSourceData _
Source:=ws.Range(ws.Cells(4 * iRow - 11, 7), _
ws.Cells(4 * iRow - 9, 9)), PlotBy:=xlRows
ActiveChart.Location Where:=xlLocationAsNewSheet, _
Name:=aName
With ActiveChart
.Name = aName
.HasTitle = True
.ChartTitle.Characters.Text = "Average Times - 1st January to 31st March 2011" & Chr(10) & Chr(10) & Chr(10) & "Consultant- " & aName & Chr(10) & Chr(10) & "Sample Size - Adv: " & Sheets("Adv & TC Ave").Cells(iRow, 5) & Chr(10) & "Sample Size - TC: " & Sheets("Adv & TC Ave").Cells(iRow, 4) & Chr(10)
.Axes(xlCategory, xlPrimary).HasTitle = False
.Axes(xlValue, xlPrimary).HasTitle = False
End With
ActiveChart.HasLegend = True
ActiveChart.Legend.Select
ActiveChart.Legend.Font.Size = 12
Selection.Position = xlTop
ActiveChart.ApplyDataLabels AutoText:=True, LegendKey:=False, _
HasLeaderLines:=False, ShowSeriesName:=False, ShowCategoryName:=False, _
ShowValue:=True, ShowPercentage:=False, ShowBubbleSize:=False
ActiveChart.SeriesCollection(2).DataLabels.Select
Selection.NumberFormat = "0"
ActiveChart.ApplyDataLabels Type:=xlDataLabelsShowValue, LegendKey:=False
ActiveChart.SeriesCollection(1).Select
With ActiveChart.ChartGroups(1)
.Overlap = -10
.GapWidth = 100
.HasSeriesLines = False
.VaryByCategories = False
End With
ActiveChart.PlotArea.Select
With Selection.Border
.ColorIndex = 16
.Weight = xlThin
.LineStyle = xlContinuous
End With
Selection.Fill.OneColorGradient Style:=msoGradientHorizontal, Variant:=3, _
Degree:=1
With Selection
.Fill.Visible = True
.Fill.ForeColor.SchemeColor = 24
End With
ActiveChart.SeriesCollection(1).Select
With Selection.Border
.Weight = xlThin
.LineStyle = xlAutomatic
End With
Selection.Shadow = False
Selection.InvertIfNegative = False
Selection.Fill.Patterned Pattern:=msoPatternLightUpwardDiagonal
With Selection
.Fill.Visible = True
.Fill.ForeColor.SchemeColor = 55
.Fill.BackColor.SchemeColor = 2
ActiveChart.SeriesCollection(2).Select
With Selection.Border
.Weight = xlThin
.LineStyle = xlAutomatic
End With
Selection.Shadow = False
Selection.InvertIfNegative = False
With Selection.Interior
.ColorIndex = 55
.Pattern = xlSolid
End With
With ActiveChart
.Axes(xlCategory, xlPrimary).HasTitle = False
.Axes(xlValue, xlPrimary).HasTitle = True
.Axes(xlValue, xlPrimary).AxisTitle.Characters.Text = _
"Average Time In Minutes"
End With
ActiveChart.Axes(xlValue).MajorGridlines.Select
With Selection.Border
.ColorIndex = 48
.Weight = xlHairline
.LineStyle = xlContinuous
End With
With ActiveChart.SeriesCollection(2).DataLabels.Select
Selection.NumberFormat = "0"
ActiveChart.SeriesCollection(1).DataLabels.Select
Selection.NumberFormat = "0"
End With
ActiveChart.Axes(xlValue).Select
With ActiveChart.Axes(xlValue)
.MinimumScaleIsAuto = 0
.MaximumScale = 60
.MinorUnitIsAuto = True
.MajorUnitIsAuto = True
.Crosses = xlAutomatic
.ReversePlotOrder = False
.ScaleType = xlLinear
.DisplayUnit = xlNone
End With
ActiveChart.ChartArea.Select
ActiveChart.Deselect
End With
ActiveChart.SeriesCollection(2).DataLabels.Select
Selection.AutoScaleFont = False
With Selection.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
ActiveChart.SeriesCollection(1).DataLabels.Select
Selection.AutoScaleFont = False
With Selection.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
ActiveChart.Axes(xlCategory).Select
Selection.TickLabels.AutoScaleFont = True
With Selection.TickLabels.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
ActiveChart.Axes(xlValue).AxisTitle.Select
Selection.AutoScaleFont = False
With Selection.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
ActiveChart.Axes(xlValue).Select
Selection.TickLabels.AutoScaleFont = True
With Selection.TickLabels.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
ActiveChart.ChartTitle.Select
Selection.AutoScaleFont = False
With Selection.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
ActiveChart.Legend.Select
Selection.AutoScaleFont = False
With Selection.Font
.Name = "Calibri"
.Size = 14
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.Underline = xlUnderlineStyleNone
.ColorIndex = xlAutomatic
.Background = xlAutomatic
End With
iRow = iRow + 1
Loop Until ws.Cells(iRow, 1) = ""
Application.DisplayAlerts = True
End Sub
Bookmarks