UIControllerEnterRow Event
Occurs when a row is entered by this
UIController and after that row was loaded from the database.
Namespace: Firefly.BoxAssembly: Firefly.Box (in Firefly.Box.dll) Version: debug-master-v:33791
public event Action EnterRow
Public Event EnterRow As Action
member EnterRow : IEvent<Action,
EventArgs>
Value
Action See the
Run method for the complete event flow.
UIController flow
This example is based on test data. The code for the entities included in this test data can be found in the documentation of
EntityThis example uses automatic tools to generate parts of the user interface. Those tools can be found in the example of the documentation of
Formusing Firefly.Box;
using System.Windows.Forms;
namespace TestFirefly.Box.Documentation
{
public class UIControllerEventFlow
{
public void NormalEventFlow()
{
var jobs = new Pubs.Jobs();
jobs.InitializeWithTestData();
var uic = new UIController
{
From = jobs,
View = UITools.GenerateFormWithGridFor("UIController events",
"notice that the SavingRow MessageBox only happens for rows that were changed" +
"\nAlso pay attention to the fact that the \"After The Run\" message " +
"will come only after the task ends",
jobs.Id,
jobs.Description)
};
uic.Load += () => MessageBox.Show("Load");
uic.Start += () => MessageBox.Show("Start");
uic.EnterRow += () => MessageBox.Show("EnterRow");
uic.LeaveRow += () => MessageBox.Show("LeaveRow");
uic.SavingRow += (b) => MessageBox.Show("SavingRow");
uic.End += () => MessageBox.Show("End");
MessageBox.Show("Before The Run");
uic.Run();
MessageBox.Show("After The Run");
}
}
}