如何计算一系列编译器的Delphi根目录?
对于Delphi 2007,IDE根目录可以在系统注册表中的[HKLM\SOFTWARE\Borland\BDS\5.0\RootDir]中找到。同样,对于 Delphi 2010,密钥是 [HKLM\SOFTWARE\CodeGear\BDS\7.0\RootDir]。但是其他编译器呢?如果您有任何其他 Delphi 编译器,您的注册表中的什么内容可以指向 IDE 根目录?
用于计算 IDE 根目录的注册表项有哪些:
- Delphi 7
- Delphi 2005
- Delphi 2006
- Delphi 2009
- Delphi XE
如果您能为所有这些编译器提供建议,请提前致谢。
For Delphi 2007, the IDE root directory can be found in the system registry at [HKLM\SOFTWARE\Borland\BDS\5.0\RootDir]. And similarly for Delphi 2010, the key is [HKLM\SOFTWARE\CodeGear\BDS\7.0\RootDir]. But what about the other compilers? If you have any other Delphi compilers, what is in your registry to point to the IDE root?
What are the registry keys to compute the IDE root directory for:
- Delphi 7
- Delphi 2005
- Delphi 2006
- Delphi 2009
- Delphi XE
Thanks in advance if you can advise for all of these compilers.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
Delphi 5:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Delphi\5.0\RootDir
Delphi 6:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Delphi\6.0\RootDir
Delphi 7:
HKEY_LOCAL_MACHINE\ SOFTWARE\Borland\Delphi\7.0\RootDir
Delphi 8(仅 .NET 产品):
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\BDS\2.0\RootDir
Delphi 2005:
HKEY_LOCAL_MACHINE\SOFTWARE \Borland\BDS\3.0\RootDir
BDS 2006:
HKEY_LOCAL_MACHINE\
SOFTWARE\Borland\BDS\4.0\RootDir Delphi 2007:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\BDS\5.0\RootDir
Delphi 2009:
HKEY_LOCAL_MACHINE\SOFTWARE\CodeGear\BDS\6.0\RootDir
Delphi 2010:
HKEY_LOCAL_MACHINE\SOFTWARE\CodeGear\BDS\7.0\RootDir
Delphi XE:< code>HKEY_LOCAL_MACHINE\SOFTWARE\Embarcadero\BDS\8.0\RootDir
以上适用于使用
HKEY_LOCAL_MACHINE\SOFTWARE
作为基本节点的 win32 系统。对于 win64 系统,使用HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node
作为基本节点。每个 Delphi 版本首次 IDE 启动时,这些值会从
HKEY_LOCAL_MACHINE\SOFTWARE\x\BDS\y.0\RootDir
复制到HKEY_CURRENT_USER\Software\x\BDS\y.0 \RootDir
,因此不要试图使用基于HKEY_CURRENT_USER
的值,因为对于从脚本构建且从不启动 IDE 的用户来说,它们永远不会存在(自动构建系统和从我想到了命令行)。我试图保留注册表项的最新版本 在我的博客中。
Delphi 5:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Delphi\5.0\RootDir
Delphi 6:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Delphi\6.0\RootDir
Delphi 7:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Delphi\7.0\RootDir
Delphi 8 (.NET-only product):
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\BDS\2.0\RootDir
Delphi 2005:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\BDS\3.0\RootDir
BDS 2006:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\BDS\4.0\RootDir
Delphi 2007:
HKEY_LOCAL_MACHINE\SOFTWARE\Borland\BDS\5.0\RootDir
Delphi 2009:
HKEY_LOCAL_MACHINE\SOFTWARE\CodeGear\BDS\6.0\RootDir
Delphi 2010:
HKEY_LOCAL_MACHINE\SOFTWARE\CodeGear\BDS\7.0\RootDir
Delphi XE:
HKEY_LOCAL_MACHINE\SOFTWARE\Embarcadero\BDS\8.0\RootDir
The above are for win32 systems that use
HKEY_LOCAL_MACHINE\SOFTWARE
as base node. For win64 systems, useHKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node
as base node.Upon first IDE start of each Delphi version, the values are copied over from
HKEY_LOCAL_MACHINE\SOFTWARE\x\BDS\y.0\RootDir
toHKEY_CURRENT_USER\Software\x\BDS\y.0\RootDir
, so do not be tempted to use theHKEY_CURRENT_USER
based values as they are never there for users that build from a script and never start the IDE (automated build systems and building from the command-line come to mind).I am trying to keep an up-to-date version of the registry keys in my blog.
我不知道这是否是您要查找的注册表项,但这是 Delphi 7 中名为“RootDir”的注册表项:
Computer\HKEY_CURRENT_USER\Software\Borland\Delphi\7.0\RootDir
![alt text][1]
I don't know if this is the registry entry that you're looking for but here's one named "RootDir" in Delphi 7:
Computer\HKEY_CURRENT_USER\Software\Borland\Delphi\7.0\RootDir
![alt text][1]