i have a problem with running my project built in Delphi CodeGear containing my own compo开发者_如何学编程nents. They (the components) use propertyeditors, so I use designide.dcp, and this compiles well and the components appear on the toolbox. But, when I use them in a new project, i can't start it. It says " 'dcc' exited with code 1" ?! I also included the package in the project in runtime packages because it didn't compile otherwise. Help, anyone, please
You probably are compiling the TPropertyEditor into a package that is marked runtime only.
The best solution is to create two packages, one that contains only the component code and that is marked as a runtime package, and the other that is marked as design-time, requires your previous runtime, and contains the TPropertyEditor.
Short of that, you can compile a single package but mark the package both runtime and design-time.
For a simple example of how it is laid out, see the article here:
http://blogs.embarcadero.com/nickhodges/2010/01/06/39345
and the code it refernces, here:
http://sourceforge.net/projects/tsmiley/
I don't know exactly what this error means, but I found it in this QC call. It seems to be a 'file not found'-like error.
I think your component is installed, but the dcus and/or runtime package are missing or are in a path that cannot be found.
The fact that it works when you compile with runtime packages also suggests that the package cannot be compiled into the executable. I'm not sure that 'error 1' means 'file not found' though. Does the compiler give any additional information?
Installing a component and/or component package is one step. You must also be sure that the Evironment Path in your Delphi IDE is pointing to the source files for the component. Double check that the path to your component source files is there, as well as the path to the toolsapi in the delphi source
精彩评论