[Lazarus] CodeCompletion: Unit not found, compile ok

Lukas Gradl fpc at ssn.at
Sun Jul 20 21:05:11 CEST 2014


Zitat von Mattias Gaertner <nc-gaertnma at netcologne.de>:

> On Sun, 20 Jul 2014 18:30:57 +0000
> Lukas Gradl <fpc at ssn.at> wrote:
>
>> I've a strange problem with Lazarus (1.3, SVN 45936M):
>>
>> Im working on a Linux-X64-Workstation but the target of the current
>> project is Win32/i386.
>>
>> I have a TDBGrid (dbgFolderDocs) on my form.
>>
>> I can compile the project, it runs correctly.
>>
>> But while coding when I press the . in the line
>> for i:=0 to dbgFolderDocs.SelectedRows
>> an error occurs (it's german, i translated it, so it might be not the
>> exact english error message):
>> Codetools, Error: 1
>> dbgrids.pas(37,65) Error: Unit not found: Variants
>>
>> How can this be - the compiler can find the unit.
>
> Variants is a standard FPC unit.

This was a good hint.

>
> If compiling works, but the IDE cannot find the unit, it means the IDE
> cannot find it in the FPC Sources.
>
> Check View / IDE Internals / About IDE:
>
> FPC source directory
> Real FPC source directory

They were set correctly. But a "Tools / ReRead FPC directory" (again:  
translated from german) fixed the problem.

Thanks
Lukas




More information about the Lazarus mailing list