WEBLib.LocalFiles

I'm using Web Core v1.6.2.0 and following this blog post. My code works, but the Delphi IDE complains

Cannot resolve unit name 'WEBLib.LocalFiles'
Undeclared identifier TTextFile
etc.

Not sure how to resolve that. I've tried adding the WEBLib.LocalFiles's source location to my path environment variable - didn't solve it.

Any ideas?

Is this in the IDE you get this or when you try to compile?

It's happening In the IDE while I'm writing code; the "Structure" panel reports a number of errors like this. Now that I've used it a lot more, I've realized that CodeInsight is not working at all - not even on normal Delphi syntactic elements. Getting very frustrating and slows down development tremendously.

If I create a new VCL project, doing things like creating...

var
  Str : TStrings;

followed by this in the body of a method...

  Str := TStringList.Create;
  Str.    <---

after typing period (.), the IDE immediately shows me CodeInsight's list of methods of the TStrings class of Str... like Add().

When I do the same in my new and mostly-bare TMS Web PWA app, there's no CodeInsight pop-up at that point and it appears that isn't working because of all the "errors" the IDE has listed in the Structure pane at that point in time (which are complaining about things that do indeed exist (and compiles properly), like WEBLib.LocalFiles and TFolder and Kind).

This is using Delphi 10.3 with TMS Web Core v1.6.2.0 installed.

It compiles and runs properly, but is very slow to develop in because I'm not fluent in Web Core yet, so I'm forced to always dig up details in the TMS source code and TMS documentation just to find names of methods I don't know yet.

I didn't see any installation notes that indicate I need to do anything special after installing TMS Web Core to make the Delphi IDE work better. Did I miss something?

Can you check your IDE library path to ensure that it only has the TMS WEB Core folder "Component Library Source" in it and not other TMS WEB Core folders?

I couldn't find an "IDE library path" but in Tools > Options I took note of the IDE > Environment Variables > Path (which is my system path).

Here's what it's set to: (I grabbed the contents and replaced ; with carriage-returns only to clarify for this post)

C:\ProgramData\Oracle\Java\javapath
C:\Program Files (x86)\Embarcadero\Studio\20.0\bin
C:\Users\jmartin\Documents\Embarcadero\Studio\20.0\Bpl
C:\Program Files (x86)\Embarcadero\Studio\20.0\bin64
C:\Users\jmartin\Documents\Embarcadero\Studio\20.0\Bpl\Win64
%SystemRoot%\system32
%SystemRoot%
%SystemRoot%\System32\Wbem
%SYSTEMROOT%\System32\WindowsPowerShell\v1.0
C:\PROGRA~2\Borland\Delphi6\Bin
C:\Program Files\Git\cmd

That looks reasonable to me (I have Delphi 10.3 and also an old Delphi 6 installed) on this relatively clean Win 7 virtual machine.

So I checked TMS Web > Options and noticed there's a Library Path field. It was empty. I set it to the path I think you mean, pictured here:

However, with that setting in place, now my project doesn't compile - it errors and opens WEBLib.StdCtrls saying that it "can't find unit "Winapi.Windows" in that unit's uses clause.

Seems strange to me - that Library Path setting overrides the IDE's standard library path?

Please let me know if I'm looking in the wrong place.

The TMS WEB Core path needs to be set to the "Core Source" and "Core Source\RTL" subfolder.
NO other folders.

The IDE library path is under Language. It should point to the "Component Library Source" subfolder.

The TMS WEB Core path needs to be set to the "Core Source" and "Core Source\RTL" subfolder.
NO other folders.

Like this?

The IDE library path is under Language. It should point to the "Component Library Source" subfolder.

And this? (This is how it was; I didn't make changes - Component Library Source is there (among others).

After ensuring all the above, I can compile again, but the original problem still remains.

Do you see the file WEBLib.LocalFiles.pas in the folder "Component Library Source" ?

Thank you very much for continuing to help me.

Do you see the file WEBLib.LocalFiles.pas in the folder "Component Library Source" ?

No, actually, it's not there:

image

It seems to be in Core Source (instead?):

image

I haven't messed with any files in the install, so this is exactly how the v1.6.2.0 installer placed them.

Also, in a desperate attempt to solve this, I'm beginning to wonder if my install of Delphi v10.3.2 (plus patches) is at fault... I'm only wondering that because of how Code Insight fails for even standard classes/methods; however, I think that only happened after installing Web Core v1.6.2.0 (or after I started trying to configure Delphi to look in the right places once I noticed the problem).

I do almost all of my development on a virtual machine and I can easily switch to another snapshot and install a newer version, fresh. Wondering if I should move to v10.3.3, or v10.4 Patch 3 (though I'm not sure yet if my purchase/maintenance allows me to run those versions).

Followed-up via email.

Solved: My problem was in using a feature before its official release (and I didn't know it).

This can be closed and the issue is expected to be fully solved in Web Core v1.7.

This topic was automatically closed 60 minutes after the last reply. New replies are no longer allowed.