Page 1 of 1

TeeChart 7.00 Error Freeing TeeChartFunction

Posted: Thu Mar 02, 2006 7:29 pm
by 9231248
Hello

I now have the issue I reported to you a while back where TCustomTeeFunction is being freed twice

This is causing me big problems at the moment, not made any easier by the fact I cant upgrade TeeChart because Digital Metaphors for no apparent reason stopped supporting TeeChart for Delphi 6 at v7

Have the issues freeing functions been resolved, and if so can a fix be applied?

The strange thing this time is that I am not creating a function at design time like I was before?

My chart is below

object ppTeeChart24: TppTeeChart
UserName = 'chProfile'
Border.BorderPositions = []
Border.Color = clBlack
Border.Style = psSolid
Border.Visible = False
Border.Weight = 1
mmHeight = 158221
mmLeft = 0
mmTop = 0
mmWidth = 284428
BandType = 4
object ppTeeChartControl1: TppTeeChartControl
Left = 0
Top = 0
Width = 400
Height = 250
BackWall.Color = clWhite
LeftWall.Visible = False
MarginBottom = 5
MarginTop = 5
Title.AdjustFrame = False
Title.Font.Charset = ANSI_CHARSET
Title.Font.Color = clBlack
Title.Font.Name = 'Verdana'
Title.Text.Strings = (
'Chart')
Title.Visible = False
BackColor = clWhite
BottomAxis.Axis.Width = 1
BottomAxis.ExactDateTime = False
BottomAxis.Grid.Visible = False
BottomAxis.Increment = 48
BottomAxis.LabelsFont.Charset = ANSI_CHARSET
BottomAxis.LabelsFont.Name = 'Verdana'
BottomAxis.LabelsOnAxis = False
BottomAxis.LabelStyle = talText
BottomAxis.MinorTicks.Visible = False
BottomAxis.RoundFirstLabel = False
BottomAxis.TicksInner.Visible = False
LeftAxis.Automatic = False
LeftAxis.AutomaticMaximum = False
LeftAxis.AutomaticMinimum = False
LeftAxis.Axis.Width = 1
LeftAxis.Grid.Visible = False
LeftAxis.LabelsFont.Charset = ANSI_CHARSET
LeftAxis.LabelsFont.Name = 'Verdana'
LeftAxis.LabelStyle = talValue
LeftAxis.Maximum = 835
LeftAxis.MinorTicks.Visible = False
LeftAxis.TicksInner.Visible = False
Legend.FontSeriesColor = True
Legend.Symbol.Visible = False
RightAxis.Axis.Width = 1
TopAxis.Axis.Visible = False
TopAxis.Grid.Visible = False
TopAxis.Ticks.Visible = False
TopAxis.TicksInner.Visible = False
TopAxis.Visible = False
View3D = False
View3DWalls = False
BevelOuter = bvNone
BorderStyle = bsNone
Color = clWhite
object Series1: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series2: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series3: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series4: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series5: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series6: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series7: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series8: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series9: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series10: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series11: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series12: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series13: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series14: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
object Series15: TLineSeries
Marks.Callout.Brush.Color = clBlack
Marks.Visible = False
Pointer.InflateMargins = True
Pointer.Style = psRectangle
Pointer.Visible = False
XValues.Name = 'X'
XValues.Order = loAscending
YValues.Name = 'Y'
YValues.Order = loNone
end
end
end
end


Cheers

Paul

Below is the information from FastMem


--------------------------------2006/1/13 12:34:28--------------------------------
FastMM has detected an attempt to call a virtual method on a freed object. An access violation will now be raised in order to abort the current operation.

Freed object class: TCustomTeeFunction

Virtual method: Destroy

Virtual method address: 430080

Stack trace of when the object was allocated (return addresses):
402AD7 [System][@GetMem]
403EF7 [System][TObject.NewInstance]
4298A5 [Classes][CreateComponent]
429B1E [Classes][TReader.ReadComponent]
42926E [Classes][TReader.EndOfList]
429D6A [Classes][TReader.ReadDataInner]
429CD8 [Classes][TReader.ReadData]
43049A [Classes][TComponent.ReadState]
429B89 [Classes][TReader.ReadComponent]
42926E [Classes][TReader.EndOfList]
429D6A [Classes][TReader.ReadDataInner]
429CD8 [Classes][TReader.ReadData]
43049A [Classes][TComponent.ReadState]
475A06 [Controls][TControl.ReadState]
478F12 [Controls][TWinControl.ReadState]
429B89 [Classes][TReader.ReadComponent]

Stack trace of when the object was subsequently freed (return addresses):
402AF7 [System][@FreeMem]
403F15 [System][TObject.FreeInstance]
404309 [System][@ClassDestroy]
4300F4 [Classes][TComponent.Destroy]
4302C5 [Classes][TComponent.DestroyComponents]
4300CC [Classes][TComponent.Destroy]
475810 [Controls][TControl.Destroy]
403F15 [System][TObject.FreeInstance]
404309 [System][@ClassDestroy]
434247 [Graphics][TBrush.Destroy]
478E02 [Controls][TWinControl.Destroy]
45F589 [Forms][TScrollingWinControl.Destroy]
460584 [Forms][TCustomForm.Destroy]
45E490 [Forms][DoneApplication]
40DB9C [SysUtils][DoExitProc]
404CFA [System][@Halt0]

The current stack trace leading to this error (return addresses):
414819 [SysUtils][FreeAndNil]
540A65 [TeEngine][TChartSeries.Destroy]
6062DD [Series][TCustomSeries.Destroy]
403F5B [System][TObject.Free]
544E88 [TeEngine][TCustomAxisPanel.FreeAllSeries]
544B38 [TeEngine][TCustomAxisPanel.Destroy]
54AEA9 [Chart][TCustomChart.Destroy]
611DE9 [ppChrt.pas][ppChrt][TppTeeChartControl.Destroy][677]
4302C5 [Classes][TComponent.DestroyComponents]
4300CC [Classes][TComponent.Destroy]
5529AA [ppComm][TppCommunicator.Destroy]
562DB8 [ppRelatv][TppRelative.Destroy]
5745F2 [ppPrnabl][TppPrintable.Destroy]
5FBAAA [ppClass][TppComponent.Destroy]
5A8A87 [ppCtrls][TppCustomComponent.Destroy]
611648 [ppChrt.pas][ppChrt][TppCustomTeeChart.Destroy][325]

Current memory dump of 256 bytes starting at pointer address 40B1FD8:
88 49 7C 00 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80
80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80
80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80
80 80 80 80 80 80 80 80 BF E0 F4 FB 80 80 80 80 00 00 00 00 70 CF 0A 04 00 00 00 00 00 00 00 00
FF FF FF FF D7 2A 40 00 F7 3E 40 00 BE 42 40 00 07 8B 43 00 81 9D 43 00 A3 91 46 00 1F 91 46 00
1E E6 47 00 FB 8F 46 00 32 FB 48 00 F6 FF 48 00 27 C0 D4 77 CF A3 47 00 D6 A3 47 00 35 17 49 00
0E A5 47 00 3D A8 40 00 1F 2B 40 00 3F 7D 42 00 E1 7A 42 00 A9 7B 42 00 64 78 42 00 1B 17 5D 00
FD 17 5D 00 75 17 5D 00 A0 17 5D 00 8F 16 5D 00 9B 58 5F 00 72 59 5F 00 76 53 5D 00 6F 44 42 00
ˆ I | . € € € € € € € € € € € € € € € € € € € € € € € € € € € €
€ € € € € € € € € € € € € € € € € € € € € € € € € € € € € € € €
€ € € € € € € € € € € € € € € € € € € € € € € € € € € € € € € €
€ € € € € € € € ¿ à ô û € € € € . . . . p Ï . . . . . . . . . .
ÿ ÿ ÿ ÿ × * @ . ÷ > @ . ¾ B @ . . ‹ C .