Link to home
Start Free TrialLog in
Avatar of Wayne Barron
Wayne BarronFlag for United States of America

asked on

[Fatal Error] Project1.dpr(1): File not found: 'System.pas' : Immediate Answer Needed Please :

Hello All;

  I need an Immediate Answer on this one please, If possible.

System Config : Win2k SP4 installed
                        Delphi 6.02 Pro

When I try to run any units I get the following
[Fatal Error] Project1.dpr(1): File not found: 'System.pas'

This just started out of the Blue late last night.

Any idea's?

I have been told that I might have to reinstall Delphi?
In hopes that this is not the case.

I have checked the following.

Library Path:   $(DELPHI)\Lib   -- >  system.dcu
I even added : $(DELPHI)\Source\Rtl\Sys ( as a test )

Browsing Path :   $(DELPHI)\Source\Rtl\Sys  --> system.pas

I did a Repair on D6 from the Control Panel.
I reinstalled both " SP2 & Runtime SP2"
And still no help

If there is no fix for it, besides a reinstall.
Can someone please tell why it happens ?

Wayne
Avatar of calinutz
calinutz
Flag of Romania image

Why is it so difficult to reinstall delphi?
Avatar of Wayne Barron

ASKER

[Clinutz];

  [Quote]Why is it so difficult to reinstall delphi?[/Quote]

Installing Delphi is not the point here, What I need to know is "if" there is a way to fix this issue, without having to Reinstall.

&
What causes it to happen?
Even though it is in the Folder that is suppose to be in.

This is what I need to know.
Reinstalling it is an option, this I know, and this I can do, but there has to be someone out there that knows how it happens and why it happens.
Avatar of snehanshu
snehanshu

Not sure about this, but could it be that Win2K is restricting Delphi's access to the "$(DELPHI)" folders?
I think Win2k has that folder level permission stuff which you may want to check.
Just a thought.
...Shu
[snehanshu];

  Permissions on all the folders are set per normal,
But I did check to make sure that nothing got messed up.

I installed SP4 for Win2k the other day.
Who knows maybe it might have something to do with it, I can try uninstalling SP4 back SP3 and see if that gets it back? But do not know, as it has been installed for several days now, and this problem happened last night after I installed a VCL Component package.?? Sort of makes me wonder if maybe that package has something to do with it? That is something that I can check on first, before installing SP4....

 carrzkiss
BTW,
  Does this registry key:
HKEY_CURRENT_USER\Software\Borland\Delphi\6.0\RootDir

  point to where $Delphi is supposed to be?
  That can be the problem too.
  Also, you may want to ensure that the frst entry in your libary path is "$(DELPHI)\Lib"
...Shu
Yes all keys are pointed correctly.
And the \lib
Is the 1st in the list.

Nothing problem now.

It is not even finding the VCL now ?
I think that it is a Complete Reinstall on this one.
Something has totally got it all messed up.

Going to end this post now.

carrzkiss

Well,
  I guess that the package you wrote about did mess up things.
  I can't think of more causes, so can't help more.
...Shu
Yep, going to contact the vendor, and see what they say?

carrzkiss
BTW, what VCL package did you install? Perhaps I can try doing the same and find out what happens (in case there's a trial version or something).
...Shu
LMD Tools v6.12.00 Pro
ASKER CERTIFIED SOLUTION
Avatar of Ferruccio Accalai
Ferruccio Accalai
Flag of Italy image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
This error message usually occurs if the lib path is too long. Unfortunately Delphi has a hard limit on how long the library path may get. Try to get it shorter. E.g. by moving the LMD folders to the root of your harddisk and by naming them not too "long".
[Ferruccio68];

 Thank you so very much :-)
That was it,,,, well sort of.
The address to the directories that the components are located in was not too long. About 30-char-long. So that is rather short considering.

What I did was add in each path indivisually, and then run the Form. and everything was doing well until I get to
Folder = lmdsh20
Once it was added, I received the Error about " system.pas"
Took it out, and the Error was gone, and Compile per normal.
Then I skipped that one, and added in the
Folder = lmdsys10
And it did the same thing, gave me the Error "System.pas"

So what I did was took ALL  " .dcu & .dfm " Files and copied them
All over into a seperate folder, and pointed just to that folder.
And no more Error.

Though some of the components are giving me Error's when I put them
On the form.
Example Error:
[Fatal Error] Unit1.pas(7): Unit LMDComponent was compiled with a different version of LMDCustomComponent.TLMDCustomComponent

I will work on figuring it out later. But right now, I am a very  Happy person, as I do not have to Reinstall :-)

Thank you to everyone.

Shu = For trying to assist.
Ferruccio68 = For your Correct information and explaination on what
The problem could & may be. This is the information that I was searching for.

Thank You
carrzkiss
Very glad to have helped you :)
Just in addition:
i have several machines with delphi installed that i use to develop my projects (4 at my office, 2 at home and 1 other laptop), so as you can guess, the difficult is in differents path locations on these differents installation (some on C drive, some other on D with different folder locations). To have always the same project folder configuration i've mapped a X virtual drive in every machine, every one pointing to a different folder, but in my delphi environment the path starts always with X:\...., so it's the same on every PC...
This means that you could map your long paths to a X:\ virtual drive. The result will be a shorter Path string. (Just for example C:\Program Files\Borland\Delphi7\MyPackages could be mapped as X:\ so a Package in C:\Program Files\Borland\Delphi7\MyPackages\MyPackage.dpk will have a [PATH] X:\MyPackage.dpk...hope you understand what i mean)

F68 ;-)
Yes, I understand.
Except in my case it was not the path, but was a folder? Which
I still do not understand, but what I did cured the problem.
And if it was not for you telling me about the Folder Path's
I wold have never known about it, and would have reinstalled Delphi, which would have been a pain in the butt.

I have Delphi installed on my Laptop as well.
Both are installed on " E:\Borland\Delphi6 "
So I have a very easy way to reinstall Delphi so that it will not take
As long to do so.
Registry Backup, The Registry is such a fun place to go into if you know what you are doing.

 Take Care and thank you once again for youe great information.

carrzkiss