Page 1 of 1

TeCanvas not found

Posted: Tue Jul 04, 2017 11:51 am
by 16581165
Hi
Just installed TeeChart pro in my Delphi. The installation process was kind of interesting, as it in the end asked me to run TeeRecompile. I did so, and was baffled that all the nodes were with (c++), so I can run it for my Delphi 10.2 Tokyo Win32 v25(C++), and so on.
I dont have C++ installed at all, I have only Delphi.
So I hit Begin anyway, and it complained it wanted some c++ headerfiles.
So I downloaded the c++ header files, and let the TeeRecompile do its thing, and it succeeded in compiling, I think...
Starting now a brand new Windows VCL Delphi project, and dropping the TeeChart component on a form and hitting Compile results in a error stating that it cannot find TeCanvas.
Googling and searching this forum I get hints that the Library path may be messed up in Delphi, so I should check this.
I searched my machine for any files Tecanvas.*, and find only in Compiled\Delphi25.win32\include\TeCanvas.hpp, the same in win64, and I find the TeCanvas.pas in Source.
Now, I know I could stick Source in my search path, but I am kind of baffled of why I dont have a TeCanvas.dcu file in my Compiled folder?

Should TeeRecompile not do exactly that?

Any suggestions on the correct way to fix this are highly appreciated.

Thanks in advance
Jens Fudge

Re: TeCanvas not found

Posted: Tue Jul 04, 2017 1:31 pm
by yeray
Hello Jens,

TeeRecompile utility prepares the sources shipped with the installation, compiles them and installs the packages into the IDE.
To prepare the sources in RAD Studio > XE it renames the units adding a prefix, VCLTee. and FMXTee. You'll find these modified sources in the "Source\VCL" and "Source\FMX" folders in your installation. These are the units that are compiled at the next stage in TeeRecompile.

We use to recommend adding "VCLTee" or "FMXTee" to the "unit scope names" list in "Tools\Options...\Environment Options\Delphi Options\Lirary" in your IDE.

If you want to directly use TeeChart sources in your IDE, you can add the "Source\VCL" or the "Source\FMX" path to your library path.

Re: TeCanvas not found

Posted: Wed Jul 05, 2017 7:51 am
by 16581165
Hello Yeray,
That seems to work.
Thank you for a swift reply

Kind regards
Jens Fudge

Re: TeCanvas not found

Posted: Wed Jul 12, 2017 9:18 am
by 16581165
TeCanvas compile error.png
TeCanvas compile error.png (178.32 KiB) Viewed 13224 times
Hi again,
Sorry to bother you, but I seem to have stumbled on another problem with the TeCanvas.pas file.

I did put VCLTee in Unit Scope names, but now on opening an existing project, and compiling it, I get the error as seen on the image attached:

Incompatible types: VCLTee.TeCanvas.TTeeCanvas and TeCanvas.TTeeCanvas

And also Incompatible types TTeeCanvas and TTeeCanvas3d

Do you have any suggestions on what to do?

Thanks in advance

Re: TeCanvas not found

Posted: Wed Jul 12, 2017 9:38 am
by yeray
Hello,

Check the library path. You probably have the "Source" path above the "Source\VCL" path (or maybe you don't have the "Source\VCL" path on the list). This would explain why the compiler is finding TeCanvas.pas (present in the "Source" folder) before finding VCLTee.TeCanvas.pas (present in "Source\VCL" folder).

Re: TeCanvas not found

Posted: Wed Jul 12, 2017 1:48 pm
by 16581165
TeCanvas compile error2.png
TeCanvas compile error2.png (44.52 KiB) Viewed 13222 times
Hello,

No, I have \Source\VCL above \Source

Re: TeCanvas not found

Posted: Wed Jul 12, 2017 1:53 pm
by yeray
Hello Jens,

If a new project works fine but an old one gives a problem, then the problem is probably in the project options. Please check the paths in the "Project/Options" too.

Re: TeCanvas not found in Delphi 10.2 Tokyo

Posted: Sat Jul 29, 2017 11:23 pm
by 16579445
Hi

I had a major problem with TeeChart and Delphi 10.2 but the advice...

Add "VCLTee" or "FMXTee" to the unit scope names sorted the issue.

Many Thanks