While compiling Delphi 5 code in Delphi 7 Enterprise Edition, i'm getting below errro
[Fatal Error] MultLang.pas(192): File not found: 'LibHelp.dcu'
I have checked all Delphi7 folders but libhelp.dcu is not present.. any advice???
I have neither LibHelp.pas nor .dcu in my D2007, but it's used in some property editors. So I guess it's design-time stuff, and any code that uses it needs to be in a design-time package requiring designide. Your comment about Proxies.dcu hints in the same direction, so I recommend separating design-time and runtime stuff in two different packages.
Related
I am upgrading a project from Delphi XE3 to Delphi Rio 10.3.3. The project contains a number of fixes to the VCL and RTL units, made by copying units from the Delphi install into a path inside the project and applying modifications. This still appears to work so long as the correct compiler options are specified in the unit, but this does not seem to work for System.Classes.pas, getting the infamous error:
F2051 Unit AAA was compiled with a different version of BBB
Has anybody been able to modify System.Classes.pas for Delphi Rio, and if so which compiler switches did you use? I note from this answer: https://stackoverflow.com/a/24145450/12683559 that this was broken in XE6 but worked again in XE7.
In Rad Studio Rio, I create a package for Delphi.
In the PAS unit, I add:
uses DesignIntf;
The compiler complains about "DesignIntf not found". Adding DesignIntf.dcp as reference solves the problem.
Now, if I create the same package but from C++ Builder, I add "uses DesignIntf;" in the PAS unit, if I add DesignIntf.bpi as reference, the error is not fixed.
Why in Delphi DesignIntf.dcp solves the problem but DesignInt.bpi does not solve it for C++Builder with exactly the same code?
UPDATE;
It is win32 platform. The following image shows how designintf.bpi is referenced but I continue getting the error. It works as expected if the package is for Delphi and using designintf.dcp.
In both Delphi and C++, your design-time package needs a reference to the DesignIDE package in order to use the DesignIntf unit.
Please read Embarcadero's documentation:
Compiling C++ Design-Time Packages That Contain Delphi Source
Creating or Extending a Package to Use the Tools API
Finally I have solved it. I missed to add -LUDesignIDE under Delphi Compiler options. It is explained at http://docwiki.embarcadero.com/RADStudio/Rio/en/Compiling_C%2B%2B_Design-Time_Packages_That_Contain_Delphi_Source
The reason is because I mix Delphi and C++ code.
I worked on my school IT project from home, on a newer Delphi (RAD Studio 10 Seattle). Now when I copied my program to work on it at school (Delphi 2010), it got an error when compiling Vcl.Forms.Dcu not found.
I have looked at other StackOverflow questions and my Unit Output Library is correctly set to $(BDSCOMMONDIR)\Dcp, so I do not know what is the problem.
The VCL unit prefixing was added in XE2 to differentiate between same-named units in the VCL and (newly added) FMX frameworks. Removing the Vcl. prefix will correct the error.
Unit Scope Names were introduced in XE2, so the Vcl.Forms unit does not exist in Delphi 2010, it was still known as Forms instead.
The correct solution in this situation is to refer to the Forms unit in your code as simply Forms, not as Vcl.Forms. In your Seattle project options, make sure that Vcl is listed in the compiler's Unit scope names configuation field.
This way, when compiling the code, D2010 will look for Forms.dcu only, and Seattle will look for Vcl.Forms.dcu when it cannot find Forms.dcu.
I'm running Delphi XE2 w/ update 3.
I've just checked out the read-only branch of DWScript from the svn repository. I try to install dwsLib.dpk from the DelphiXE2 folder but receive the following error:
[DCC Fatal Error] dwsLibRuntime.dpk(30): E2225 Never-build package 'designide' must be recompiled
I tried building dwsLibRuntime.dpk first, but I get an error about missing TdwsUnit component, so that doesn't work, either. I'm not having any luck finding contact info for the author, so am trying here.
Any advice would be greatly appreciated.
The short answer is: DWScript doesn't target Delphi XE2.
Quote:
DWScript lead platform is currently Delphi XE, compatibility with
Delphi 2009 & Delphi 2010 is maintained, but some features may be
restricted (RTTI f.i.).
You must fix the source code if you want it to work with Delphi XE2.
I.am using XE2 with the trunk code and it works fine. I loaded up each dpi (there are two) and built and installed the first. Then compile your code ensuring that you point to the source folders (there are at least three). Failing that I'll post you an innosetup exe that installs it into XE2 that I've made,
First of all, I have never written a property editor from scratch, but had some help with one in another question. Refer to the accepted answer there. This was in Delphi 7, and now I have started using XE2 and I have to make sure my property editor is compatible with both 7 and XE2.
It's essentially a collection editor, with the difference that each collection item has its own named component in the parent form. Is there anything new about the property editors in XE2 since 7, since it is a huge version jump?
I do NOT want to make a complete copy of my unit for different versions. I want to maintain all possible versions in one unit.
Edit
It appears that Delphi XE2 has the same property editors as Delphi 7, but the issue I was facing was that although I was including DesignIDE in my package, it could not find anything, so I had to add the ToolsAPI folder to my library path.
However, now I have a new issue after this.
[DCC Fatal Error] ToolsAPI.pas(18): F1026 File not found: 'DockForm.dcu'
I'm lost in the whole concept of BPL packages and requiring others, etc.
DesignIntf, DesignEditors, DesignMenus, DesignWindows are part of DesignIDE.bpl and is found in \Embarcadero\RAD_Studio\9.0\lib\win32\release\designide.dcp. But there is no designide.dcp for 64bit which is why it throws an error when compiling a 64bit package that references these units.
There is no 64bit version of DesignIDE because it is for a design time package and design time packages are 32 bit only (remember Delphi IDE is still only 32 bits). So always set your design time package as 32bit, not 64bit. :)
Mike
The DockForm.pas source code is available neither in Delphi XE nor in Delphi XE2.
You may try this accepted answer posted on SO applying to similar issue on Delphi 2010.
Presumably, it is compiled and included within some package already distributed with Delphi XE2.