Create Component TMSWebCore

Hi
I try to create WebCore Component.
Tried to derive it from TComponent
But compilation fails in WebLib.Controls
[dcc32 Fatal Error] WEBLib.Controls.pas(27): F2613 Unit 'ExtCtrls' not found.
I didn't find such file on disc.

Demos compile fine.
TMSWebCore 2.5.3.0
Ilia

Please share full source code so we can see what exactly you are doing

TMSWrapper.zip (6.3 KB)

I do nothing special. Just empty Component.
Just installed Delphi. And Just installed TMSWebore. Everything is fresh new.

Ilia

What you created is for compiling with pas2js compiler.
I assume you try to compile this here with the DCC32 compiler.
So, in Delphi, you should not compile this with DCC32. Make sure the unit UAlcorGrid.pas is in your TMS WEB Core library path and then you can add it to your TMS WEB Core project units and compile these.

Actually
I try to make Component and Install it.
Looks I can compile this web Library and install via "project manager" but component is not registered. (I get Message that package is installed but not list of registered components)
Even I have register procedure.
Looks like I miss something but what?

I attached new project.

Ilia

TMSWrapper.zip (3.1 MB)

This is a package for use to install in TMS WEB Core for Visual Studio Code where the design-time component is the same as the run-time component.
This is not the case in Delphi where the form designer only accepts VCL controls. So, for Delphi you need to create a stub control for design-time use. You can find all the example code for such stub controls for the entire framework of TMS WEB Core in the install folder under subfolder "Component Library Source".

Dear Bruno

I tried to but can't make it.

I found that Login Component is registered in 2 Places.
Only I found is WebReg.pas and weblibReg.pas.
If I take WEBLib.Login and use its sources in my unit I get an error
while compile (VCL). So there should be somewhere stub class but I didn't find it.

Could you be so kind to make just one simple component that does nothing as one folder that I would be able to install.

thanks a lot.

Here is the source code of the presentation given at TMS Training Days 2023

webcomponents.zip (99.4 KB)

You can find the session itself here:

1 Like

Thanks very much :)