[英]Delphi Object Pascal corresponding run-time calls of TBindNavigator
My question is about Delphi Object Pascal corresponding run-time calls of TBindNavigator component buttons. 我的问题是有关TBindNavigator组件按钮的Delphi对象Pascal相应的运行时调用。 I'm interesting of the following buttons: 我对以下按钮很感兴趣:
How can I implement it in the code without TBindNavigator? 没有TBindNavigator的情况下如何在代码中实现它? Would you please clarify this issue? 您能否澄清这个问题? Thanks. 谢谢。
If you wish to implement the necessary actions with simultaneous check if they are enabled etc. then you do not need TBindNavigator
at all. 如果您希望同时执行必要的操作并检查它们是否已启用等,则完全不需要TBindNavigator
。 The easiest way is the following: 最简单的方法如下:
The sample for an FMX Form: FMX表单的示例:
TActionList
to your form. 将TActionList
添加到您的窗体。 New Standard Action
form LiveBindings
node of necessary TFMXBindNavigatePost
, TFMXBindNavigateCancel
etc. class. 添加必要的TFMXBindNavigatePost
, TFMXBindNavigateCancel
等类的New Standard Action
表单LiveBindings
节点。 Datasource
property. 选择此操作并设置Datasource
属性。 TButton
or other control. 将操作分配给必要的TButton
或其他控件。 Steps 2-4 can be done in the other way as well. 步骤2-4也可以用其他方式完成。
TButton
), select property Action
and click the arrow on the right. 选择控件(即TButton
),选择属性Action
,然后单击右侧的箭头。 New standard action
then LiveBindings
. 选择“ New standard action
然后选择New standard action
LiveBindings
。 Select the necessary class TFMXBindNavigate*
. 选择必要的类TFMXBindNavigate*
。 The action will be assigned to the TButton
. 该动作将分配给TButton
。 TActionList
and choose the added action and set DataSource
property. 选择TActionList
并选择添加的操作并设置DataSource
属性。 The action will be kept up-to-date by LiveBindings
. 该操作将通过LiveBindings
保持最新。 The necessary controls will become Enabled
- Disabled
and will act as buttons of TBindNavigator
. 必要的控件将变为Enabled
- Disabled
,并将用作TBindNavigator
按钮。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.