Mobile Impact Platform solutions commonly utilize workflow as one of many components on a form. Here I will show how to implement some simple workflow through the script editor in the NextGen Designer.

Workflow is to be implemented using the AfterOpen and ServerQueueing method as shown here. This is a simple example where inspectors will open new form sessions and when they finish the session, it will be sent to an Approvers queue who will review the form, and once they finish the session it will be sent to a Managers queue. Finally, when a manager finishes the session, it goes to the finished queue on the Mi-Enterprise Middleware Server.

So the workflow is as follows..

Inspectors -> Approvers -> Managers -> Finished

In the Client-Side, JavaScript editor:

// Triggered when the form is opened

function EH_AfterOpen() {

// person to open new form session will be an inspector so set hidden value to Inspectors

    _form.setValue("_hdCurrentQueue", "Inspectors");


In the Server-Side, VB .NET editor:

    ' Triggered when an app changes user queues
    <MiCode(FormScriptEventType.ServerQueuing)> _
    Public Sub Form_ServerQueuing(ByVal e As ServerQueuingEventArgs)
        If _hdCurrentQueue.Value = "Inspectors" Then
            'currently in inspectors queue, now move session to approver queue
            e.NewQueue = "Approvers"
            e.NewQueueDetails = "Inspector has finished form, now move to approvers"
         _hdCurrentQueue.Value = "Approvers"
        Else If _hdCurrentQueue.Value = "Approvers" Then
            e.NewQueue = "Managers"
            e.NewQueueDetails = "Approver has finished with form, now move to Managers"
            _hdCurrentQueue.Value = "Managers"
        Else If _hdCurrentQueue.Value = "Managers" Then
		    'Do nothing as the session will automatically go to Finished if not directed else where.
        End If

    End Sub


Typically it is best practice to store the current Queue into a hidden control, like above, so the value can be accessed throughout all form methods. This allows for flexibility to hide, show, enable, or disable certain aspects of the form depending on what Queue the session is currently in.