UpdateChart secundario público ()
ChtObj dévil como ChartObject
PriceType dévil como de largo
Fijar ChtObj = ActiveSheet.ChartObjects (1)
Application.ScreenUpdating = falso
PriceType = ActiveSheet.Cells (13, 20). Valor
Si PriceType = 1 entonces
Con ChtObj.Chart.SeriesCollection (1)
. Valores = ActiveSheet.Range (“771: 1475”)
.MarkerBackgroundColorIndex = 1
.MarkerBackgroundColorIndex = 4
Extremo con
ChtObj.Visible = verdad
ElseIf PriceType = 2 entonces
Con ChtObj.Chart.SeriesCollection (1)
. Valores = ActiveSheet.Range (“$D$771: $D$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 5
Extremo con
ChtObj.Visible = verdad
ElseIf PriceType = 3 entonces
Con ChtObj.Chart.SeriesCollection (1)
. Valores = ActiveSheet.Range (“$E$771: $E$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 3
Extremo con
ChtObj.Visible = verdad
ElseIf PriceType = 4 entonces
Con ChtObj.Chart.SeriesCollection (1)
. Valores = ActiveSheet.Range (“$I$771: $I$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 9
Extremo con
ChtObj.Visible = verdad
ElseIf PriceType = 5 entonces
Con ChtObj.Chart.SeriesCollection (1)
. Valores = ActiveSheet.Range (“$F$771: $F$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 7
Extremo con
ChtObj.Visible = verdad
ElseIf PriceType = 6 entonces
Con ChtObj.Chart.SeriesCollection (1)
. Valores = ActiveSheet.Range (“D$771: $D$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 5
Extremo con
ActiveChart.SeriesCollection.NewSeries
Con ChtObj.Chart.SeriesCollection (2)
. Valores = ActiveSheet.Range (“E$771: $E$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 3
Extremo con
ActiveChart.SeriesCollection.NewSeries
Con ChtObj.Chart.SeriesCollection (3)
. Valores = ActiveSheet.Range (“I$771: $I$1475”)
.MarkerForegroundColorIndex = 1
.MarkerBackgroundColorIndex = 9
Extremo con
ChtObj.Visible = verdad
Terminar si
ActiveSheet.PivotTables (“PivotTable3”) .PivotCache.Refresh
Application.ScreenUpdating = verdad
Submarino del extremo
|