[Error] System.SysUtils.pas(4496): identifier not found "Sysutils"

Have a PWA that I have been working on for the past couple of months, has been working until I attempted to compile today and this is the error that I received during compilation "[Error] System.SysUtils.pas(4496): identifier not found "Sysutils"". I loaded a different program and it compiled correctly. I was using WebCore 1.4.0, I updated to 1.5.0 hoping that it would fix it, and it did not. I'm honestly not sure where to proceed at this point. Delphi 10.3 with WebCore 1.5.0. Any ideas?

So, after a few hours of trying to solve this problem, apparently this is the error that you get if you remove a form from your project yet are still including it in your "Uses" area. It may be beneficial to have a different compiler error if possible.

Are you referring to the uses list of the project .DPR file?
Normally the Delphi IDE should remove this (just like it does for VCL or FMX apps)

If you remove a Form by right-clicking the form name in the project viewer and selecting 'Remove From Project', but are still including the form in your Uses clause of another one of your forms, this is the error that you receive.

So far I could not reproduce this.

Adding a form adds:
Unit2 in 'Unit2.pas' {Form2: TWebForm} {*.html};
in the uses clause of project1.dpr

Remove it, also removes this line of code from it.

Here's my example that I did. Unit 'Main' is a form, Units Data and Orders are also forms in the same project. If I remove Orders from the project, it will still stay in the Uses of Main and if I am not calling Orders anywhere other than Uses, the project will not error until compilation with the error shown.

unit Main;


System.SysUtils, System.Classes, JS, Web, WEBLib.Graphics, WEBLib.Controls,
WEBLib.Forms, WEBLib.Dialogs, Vcl.Controls, WEBLib.ExtCtrls, Vcl.StdCtrls,

TFMain = class(TWebForm)
MainPnl: TWebPanel;
WebButton4: TWebButton;
WebButton1: TWebButton;
procedure WebButton4Click(Sender: TObject);
procedure WebFormShow(Sender: TObject);
procedure WebFormResize(Sender: TObject);
{ Private declarations }
{ Public declarations }

FMain: TFMain;


Uses Data,Orders;

{$R *.dfm}

It is your responsibility to clean up these unit references.
Delphi will also not clean this up when you do this in a VCL application.

I understand that, was only suggesting that it may be useful to have a better error in case someone else makes the same mistake in the future.

I have a unit developed in VCL, but intended to be cross framework and it called System.SysUtils, The first time I tried to compile it, I got the same error, so worked through them. There are 3 or 4 dozen instances of the error listed in the first post for this thread, mostly in the TStringHelper class. I also wrote 3 helper helper functions to help the helper. Eventually it all works. What I should have done was change "System.SysUtils" to "SysUtils" in the uses clause, so that it used the other sysutils unit and I have done that now. I think I need to define an {$IFDEF WEBCORE}, or perhaps I have missed that as well. Anyway, working now, in both formats as far as I can tell.