cro*_*don 5 delphi delphi-2009
我有一个自定义组件包,可以编译和安装安装没有问题.包的源文件位于我的库路径中,生成的bpl文件的位置也是如此.安装后,包和组件正确显示在"设计包"列表中.但是,它们不会出现在工具选项板中.
但是,每当我打开包含其中一个组件的表单时,我都会收到类找不到错误,并且dfm将无法打开.该项目编译正常,我可以查看所有的pas文件,但表单将不会显示在设计器中.
我在这做错了什么?如何在表单设计器中正确显示组件?
这是我的组件注册码:
RegisterComponents('QuoteSystem', [
TFnpLabelNumericEdit,
TPBxCheckBox,
TPBxCheckBoxSub,
TPBxComboBoxSub,
TPBxListBoxSub,
TPBxRadioItemSub,
TFnpNumericEdit,
TQGlobals,
TPBItem,
TPBxCheckListBox,
TPBxCheckListBox,
TPBxComboBox,
TPBxDateEdit,
TPBxDescList,
TPBxEdit,
TpbxInteger,
TPBxLabel,
TPBxLabeledEdit,
TPBxLabelNumericEdit,
TPBxListBox,
TPBxMemo,
TPBxNumericEdit,
TPBxQuoteElement,
TPBxRadioGroup,
TPBxRadioItem,
TPBxRichEdit,
TPBxSpinEdit,
TpbxSummaryGlobals,
TAlignEdit
]);
Run Code Online (Sandbox Code Playgroud)
你必须像这样注册你的组件
RegisterComponents ('Custom', [TMyCustomComp1, TMyCustomComp2]);
Run Code Online (Sandbox Code Playgroud)
否则 IDE 将无法在表单设计器中创建组件。