Anschließend soll ein Diagramm automatisch aus diesen Daten erstellt werden.
Wie kann ich das aus der DAtei daten.xls machen?
Hier mein MakroCode:
Charts.Add
ActiveChart.ChartType = xlColumnClustered
ActiveChart.SetSourceData Source:=Sheets("Tabelle1").Range("R1")
ActiveChart.SeriesCollection.NewSeries
ActiveChart.SeriesCollection(1).XValues = "=Tabelle1!R1C2:R1C16"
ActiveChart.SeriesCollection(1).Values = "=Tabelle1!R2C2:R2C16"
ActiveChart.Location Where:=xlLocationAsObject, Name:="Tabelle1"
With ActiveChart
.HasTitle = False
.Axes(xlCategory, xlPrimary).HasTitle = False
.Axes(xlValue, xlPrimary).HasTitle = False
End With
ActiveChart.SetSourceData Source:=Sheets("Tabelle1").Range("B1:P6"), PlotBy _
:=xlRows
ActiveChart.SetSourceData Source:=Sheets("Tabelle1").Range("B1:P2"), PlotBy _
:=xlRows