views:

239

answers:

2

Delphi 2006, whenever started afresh, loses component package. This happens on a daily bases. We have component packages with custom VCL components that we wrote ourselves. When starting up Delphi 2006, nothing is noted. But as soon as I open a form that has some of these components on it, I receive

bds.exe - Unable To Locate Component

This application has failed to start because DclOpusRep2006.bpl was not found. Re-installing the application may fix this problem.

When I then try to reinstall the component package, two things might happen:

  1. I get an empy list of design packages and have to go to regedit to delete the package in question before being able to add it anew.
  2. I get the list of design packages allright and it does show me the package in question as loaded and available.

The package is alsways available on a local drive, yet not the one Delphi resides on. Any ideas in troubleshooting?

Just to clarify my problem based on first answer: I am the sole developer on this project. The library has been installed from the same location it still resides and the path in the component packages list is correct.

A: 

I'm guessing the following may have happened:

  • The component package was installed
  • The file was moved (or perhaps 2 or more developers are using projects that use it, and the files live in different locations on their PC's)
  • Not all the paths were updated to reflect the new location.

My suggestion in this case would be to find all the project files that reference this component library and update the path.

If you are on a team and your team members have this file installed to different locations on each machine, standardise the location across all PC's.

Bork Blatt
No team, no relocation of file, path in component list is correct. Any other ideas?
Ralph Rickenbach
+2  A: 

The BPL or one of its dependencies could not be found. They may have been found during the installation of the package because of the current directory of the BDS process at the time but not found later because the current directory was then different.

Always make sure your BPLs and all their dependencies (statically linked BPLs and DLLs) are in a directory which is included in the system path.

TOndrej
Just added the path to PATH environment variable and that seemed to fix the problem. Thanks a lot!
Ralph Rickenbach
Welcome, I'm glad I could help.
TOndrej