Incompatible types TTeeFunctionClass and TSmoothingFunction

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
nickmalden
Newbie
Newbie
Posts: 3
Joined: Wed Oct 30, 2019 12:00 am

Incompatible types TTeeFunctionClass and TSmoothingFunction

Post by nickmalden » Fri Aug 21, 2020 6:44 am

Hello

I have just set up a new machine with Delphi XE5 and XE10.4 Sydney. I have applied all patches.
I have installed TeeChartVCLFMXSOURCE-2020.30.exe and compiled everything for both versions.
XE5 is running fine, but when compiling a copy of the same code in XE10.4 Sydney I get the error:

VCLTee.TeeSpline.pas(634): E2010 Incompatiple types 'TTeeFunctionClass' and class of 'TSmoothingFunction'

Code: Select all

initialization
  RegisterTeeFunction( TSmoothingFunction, @TeeMsg_FunctionSmooth,   //<< This line highlighted
                                           @
     {$IFDEF TEELITE}TeeMsg_GalleryStandard{$ELSE}TeeMsg_GalleryExtended{$ENDIF});
finalization
  UnRegisterTeeFunctions([TSmoothingFunction]);
end.
Any ideas please? I have added FMXTee;VCLTee to the Unit Scope names.

Thanks
Nick

nickmalden
Newbie
Newbie
Posts: 3
Joined: Wed Oct 30, 2019 12:00 am

Re: Incompatible types TTeeFunctionClass and TSmoothingFunction

Post by nickmalden » Fri Aug 21, 2020 8:48 am

I've found the answer. I had just copied the project sources from the XE5 folder to the XE10 folder.
I needed to then delete the XE10 .dproj files as they still point to the XE5 folders/components.
Might be worth keeping this as others may do the same.

Yeray
Site Admin
Site Admin
Posts: 9614
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: Incompatible types TTeeFunctionClass and TSmoothingFunction

Post by Yeray » Mon Aug 24, 2020 1:48 pm

I'm glad to hear you found how to solve it.
Thanks for sharing.
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

SteemaUser
Newbie
Newbie
Posts: 10
Joined: Wed Aug 05, 2020 12:00 am

Re: Incompatible types TTeeFunctionClass and TSmoothingFunction

Post by SteemaUser » Wed Jun 09, 2021 2:09 pm

I ran into a similar problem (Rad Studio 10.4.2 with patches as of today's date, and TeeChart Pro v2021.31 with Source)

The OP's solution didn't work for me (i.e. I tried deleting the .dproj file to create a new one).

It seems to me that what is happening is that the (VCL) project was somehow ending up attempting to use the FMX version of the source TeeSpline.pas for some reason.

To work around it, I changed the order in which the Unit Scope Names are listed in Tools/Options.

Originally, I was doing this:
Tools/Options, Language, Delphi Options, Library, Unit scope names
Paste this into the combo: FMXTee;VCLTee

Everything started working when I did this instead:
Tools/Options, Language, Delphi Options, Library, Unit scope names
Paste this into the combo: VCLTee;FMXTee

Marc
Site Admin
Site Admin
Posts: 1272
Joined: Thu Oct 16, 2003 4:00 am
Location: Girona
Contact:

Re: Incompatible types TTeeFunctionClass and TSmoothingFunction

Post by Marc » Wed Jun 30, 2021 10:10 am

Thanks for the feedback!

Regards,
Marc Meuman
Steema Support

Post Reply