[This is preliminary documentation and is subject to change.]

Changes the UIController to be controlled by the user flow

Namespace:  Firefly.Box
Assembly:  Firefly.Box (in Firefly.Box.dll) Version: 3.4.23.6473 (3.4.23.6473)

Syntax

C#
public UserFlow UseUserFlow()
Visual Basic (Declaration)
Public Function UseUserFlow As UserFlow
Visual C++
public:
UserFlow^ UseUserFlow()

Return Value

An UserFlow that can be used to add action's that will be performed as part of the flow

Remarks

When this method is called, the tab order of the controls on the form, is determined by the order in which the columns were added to the Columns collection and is no longer controlled by the [!:IControl.TabIndex] of the controls.
Actions to perform between the columns, can be added using the UserFlow object returned by this method.

Examples

Basic usage of Flow UIController
This example is based on test data. The code for the entities included in this test data can be found in the documentation of Entity
This example uses automatic tools to generate parts of the user interface. Those tools can be found in the example of the documentation of Form
CopyC#
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Firefly.Box;

namespace TestFirefly.Box.Documentation
{
    class FlowUIControllerDemo
    {
        public void Run()
        {
            var jobs = new Pubs.Jobs();
            jobs.InitializeWithTestData();

            var settings = new UIController.AdvancedSettings();
            var flow = settings.UseUserFlow();

            var uic = new UIController(settings)
            {
                From = jobs,
                View = UITools.GenerateFormWithGridFor("Demonstrate UseUserFlow",
                                                       "Notice that the first parked control is \"Description\". That is because \n"+
                                                       "the \"Description\" column was added first to the Columns Array.\n"+
                                                       "Move to the \"Min Level\" column, and press tab. You'll see that a \n"+
                                                       "MessageBox appears, as was specified by the \"Flow.Add\" method that was called \n"+
                                                       "between the \"Min Level\" and the \"Max Level\" columns. ",
                                                       jobs.Id,
                                                       jobs.Description,
                                                       jobs.MinLevel,
                                                       jobs.MaxLevel)
            };
            uic.Columns.Add(jobs.Description);
            uic.Columns.Add(jobs.Id);
            uic.Columns.Add(jobs.MinLevel);
            flow.Add(()=>System.Windows.Forms.MessageBox.Show("I happen between min level, and max level"));
            uic.Columns.Add(jobs.MaxLevel);


            uic.Run();
        }
    }
}

Examples

This example demonstrates the usage of DemoFlowMode
CopyC#

See Also