gpt4 book ai didi

delphi - 如何动态添加面板到TCategoryPanelGroup?

转载 作者:行者123 更新时间:2023-12-03 15:20:23 26 4
gpt4 key购买 nike

如何动态地将面板添加到 TCategoryPanelGroup。

请举个例子,谢谢。

到目前为止我已经尝试过了。

procedure TWForm.BitBtn3Click(Sender: TObject);
var
categorypanel: tcategorypanel;
begin
categorypanel := categorypanel.Create (categorypanelgroup1);
categorypanel := tcategorypanel.Create(self);
categorypanel.caption:=edit1.text;
end;

最佳答案

您必须创建该组件,然后设置 CategoryPanelPanelGroup 属性与 CategoryPanelGroup。

Var
LPanel : TCategoryPanel;
begin
LPanel:=TCategoryPanel.Create(CategoryPanelGroup1);
LPanel.Caption:='My Panel';
LPanel.PanelGroup:=CategoryPanelGroup1;
end;

关于delphi - 如何动态添加面板到TCategoryPanelGroup?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9528491/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com