Win7 64bit, Laz 1.8.4 FPC 3.0.4
New to Lazarus, but not to programming.
(Actually Borland Delhi was my first OOP after Commodore 64, and Turbo Basic.
I know many things have changed.)
Creating my own things.
I'm getting an "EInvalidOperation" exception: "Control '' has no parent window" it claims. (image)
Exception do give a filename and a location - (don't know if theres a call stack somewhere...) - but no referance to my own code.
So I set breakpoints, and inspect variables and values.
And I find the excpetion occurs in my code, at a line that says (image)
lh := Self.Canvas.TextHeight('Tekstgy');
(Purpose is to get the height of a text in the control, for later adding a suitable number of labels...)
Self DO have a name - not sure why the exception claims it does not..
Anyhow - image show clearly, that there apparently is an attempt to call something other than what is in the sourcecode...
Self.Canvas.TextHeightTextHeightTextHeight
is not really what it says right there....
So the error in my code, comes from?
any explanation?
Or hint on how to avoid this kind of things?