Great. I see what you're getting at there, now. Thinking along those
lines I did this (below) without needing to change the base class.
Seems to work ok, anyway.
Thanks! Thanks also Roger. I'll keep that for my backup plan in case
I have other problems with this later.
Robin
type
TClassOfAbstractClass = class of TAbstractClass;
...
class function TAbstractClass.Clone(ConcreteInstance:
TAbstractClass): TAbstractClass;
var
ClassOfConcreteInstance: TClassOfAbstractClass;
begin
ClassOfConcreteInstance :=
TClassOfAbstractClass(ConcreteInstance.ClassType);
Result := TClassOfAbstractClass.Create as TAbstractClass;
...
end;
On 9 May 2005, at 21:37, Long Dong Silver wrote:
> I'm not so sure about this, but I think that what is beeing called on
> your code is "TObject.Create" since TClass is a "class of Object"...
> And as the Create method of TObject isn't a virtual nor dinamic
> method, it just calls that simple method that has no code inside...
-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/delphi-en/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/