My FNZ Studio Version

Screen-Driven Model

Latest Update: 11.02.2022 | Margherita Taffarel
Documentation
2024
2023
2022.2
2022.1
11

The Chat Channel Screen component and the ChatChannel Extension are deprecated in Appway 11 and will be removed in two years or later from their deprecation.

The Chat Channel Screen Component is an Interaction Channel, which means it is self-adapting and populated dynamically based on a given data context. The Chat Channel is designed for use with the Data Logic Business Object and bases the exact appearance and order of the chat on the underlying Data Logic Business Object. Depending on the data defined in the Data Logic, the Chat Channel renders input fields, date pickers, dropdown lists, or buttons and displays them as a conversation.

Consider that the Data Logic Business Object has undergone several changes in Appway 10. Make sure you check the corresponding  documentation. Pay special attention to changes in naming and terminology.

Note: The ChatChannel extension must be installed to use the Chat Channel Screen Component.

1 General Usage

To "connect" a Chat Channel Screen Component to a Data Logic Business Object:

  1. Create a new Screen which uses at least the Chat Channel Screen Component. You can use other layout features such as Layout Containers etc. to enhance the appearance of the Screen.
  2. Configure the Chat Channel on the available tabs for settings (see the following section).
  3. Select this Screen in a Data Task Process Component along with a Data Logic Business Object.
    Note: Using the Chat Channel with Data Logic Screens is not supported.

2 Settings

The Chat Channel is configured on the following tabs.

2.1 Properties

The following properties are available:

  • Responder Name – Defines the name displayed before the messages of the responder. "Responder" refers to the part of the chat generated by the Chat Channel.
  • User Name – Defines the name of the user interacting with the Chat Channel.
  • Send Sound – Defines the sound played when a message is sent. Set to Not Set to not use a sound.
  • Receive Sound – Defines the sound played when a message is received. Set to Not Set to not use a sound.
  • HTML Id – Sets the HTML ID of the Chat Channel.
  • Show Responder Image – When selected, you can define an image to display next to the responder's messages.
  • Show User Image – When selected, you can define an image to display next to the user's messages.

2.2 Labels

Define labels to use in the Chat Channel UI texts:

  • Confirm Answer – Defines the label of the button with which users submit their entries.
    Default: 'OK' / Label: aw.ChatChannel.answerConfirm
  • Edit Previous Answer – Automatic user response inserted into the chat when the user selects the Edit icon to change an earlier answer.
    Default: 'I changed my mind about an earlier answer' / Label: aw.ChatChannel.answerEditedResponse
  • Can't Edit Previous Answer – Defines the label displayed when a previous answer can no longer be edited. This can occur when an answer was given to a question which is no longer available due to a sentry.
    Default: 'I can't edit that question, as it no longer needs to be answered' / Label: aw.ChatChannel.answerCantBeEditedResponse
  • Pending Answer – Automatic user response inserted into the chat when the user submits an empty answer.
    Default: 'I don't want to answer this right now.' / Label: aw.ChatChannel.answerPendingResponse
  • Select – Defines the label displayed when possible answers are displayed in a dropdown list.
    Default: 'Select…' / Label: aw.ChatChannel.select
  • No End Data Task Error – Defines the label displayed if there is no End Task Action to display at the end of the conversation (no End Task Action Control defined, or no End Task Action to display due to Sentry settings).
    Default: 'This chat cannot finish due to an error (the chat has concluded, but its corresponding Data Task can't be ended). Please contact support' / Label: aw.chatChannel.noEndCaseError

2.3 Style

Define the 'Style' Business Object to use for the Chat Channel. The following parts of the Chat Channel can be styled individually (the numbers in brackets refer to the below image):

  • Edit Icon (5) – Defines the icon which allows users to edit previous answers. The icon is placed to the left of the user's answers.
  • Bubble Area (1) – Defines the styling of the upper part of the Chat Channel where the conversation takes place.
  • Interaction Area (7) – Defines the styling of the lower part of the Chat Channel where users enter their answers.
  • Responder Name (2) – Defines the text style in which the responder name is displayed.
  • Bubble Responder (3) – Defines the styling of the speech bubble containing the responder's statements.
  • User Name (4) – Defines the text style in which the user name is displayed.
  • Bubble User (6) – Defines the styling of the speech bubble containing the user's answers.
  • Answer Text Field – Defines the styling of single line text fields in the interaction area.
  • Answer Text Field Confirm Button – Defines the styling of the confirmation button displayed with single line text fields in the interaction area.
  • Answer Text Area (8) – Defines the styling of multiline text areas in the interaction area.
  • Answer Text Area Confirm Button (9) – Defines the styling of the confirmation button displayed with multiline text areas in the interaction area.
  • Single Choice Dropdown List – Defines the styling of Dropdown Lists in the interaction area from which users can select from an array of predefined answers (displayed for controls for which a Catalog with 4 or more entries is defined).
  • Single Choice Button – Defines the styling of Buttons in the interaction area with which users can select one of the predefined answers (displayed for controls for which a Catalog with 3 or less entries is defined).
  • Date Picker – Defines the styling of Date Pickers in the interaction area (displayed for controls with the Date variable type).
  • Action Button – Defines the styling of the buttons representing End Task actions.

Note: See 'Style' Business Object for more general information.

CC00new.png

3 Chat Channel Rendering

The exact appearance of items in the Chat Channel UI depends on the settings in the Data Logic Business Object:

See the below images for detailed information on how the settings in the Data Logic are interpreted into UI elements by the Chat Channel:

Image 1:

CC01new.png

The elements available here are:

  1. The Responder Name defined in the Chat Channel properties.
  2. The Responder Image defined in the Chat Channel properties.
  3. A message not requiring an answer, defined in the Data Logic by a Section Group/Field Set Group Control with an Extended Label property defined.
  4. A question with a text field for the answer, defined in the Data Logic by a Primitive Control for a String variable, using the Extended Label property.

Image 2:
CC02new.png

The elements available here are:

  1. The User Name defined in the Chat Channel properties.
  2. The edit icon available for each user response, clicking on it allows the user to change their response.
  3. The response entered by the user.

Image 3:

CC05.png

A question providing a Dropdown List for selecting the answer, defined in the Data Logic:

  • As a Primitive Control for a String variable, using the Extended Label property.
  • Using a Catalog with 4 or more entries (defined through the Catalog Values Rule on the Data Rules tab).

Image 4:

CC04.png
A question providing Buttons for selecting the answer, defined in the Data Logic:

  • As a Primitive Control for a String variable, using the Extended Label property.
  • Using a Catalog with 3 or less entries (defined through the Catalog Values Rule on the Data Rules tab).

Image 5:

CC03.png
A question providing a Date Picker for selecting the answer, defined in the Data Logic as a Primitive Control for a Date variable, using the Extended Label property.

Image 6:

CC06.png
A Button (1) allowing to end the Data Task Instance, defined as an End Task Action Control in the Data Logic, using the Extended Label.

4 Chat Channel – Design Considerations for the Data Logic Business Object

In general, the rules outlined in the Data Logic section apply. This section summarizes a number of special considerations that apply when designing a Data Logic for use with the Chat Channel:

  • In all controls, use the Extended Label property to define the text the Chat Channel displays.

  • Use Section Group/ Field Set Group Controls for messages that do not require a response (define the message to use in the chat as an Extended Label).

  • The controls defined on the Controls tab are evaluated and displayed in the Chat Channel from the top downwards. When the first End Task Action Control is reached on the Controls tab, the Chat Channel renders all End Task Actions which were defined and are not set to disabled or hidden by a sentry.

    Important! Any controls defined after the first End Task Action in the sequence of Controls are ignored by the Chat Channel.
  • Controls whose Sentry returns disabled or hidden are ignored by the Chat Channel.

  • Data Rules can be used for the following purposes:

    • To define a Catalog to provide a fixed set of possible answers for a Data Control defined on the Controls tab (rendered as Buttons, or as a Dropdown List if the Catalog contains four or more entries). In this case, use a Catalog Values Rule.
    • To render a Multiline text area for the answer, use a Single Property Expression Rule (this option is only available if the variable type is String).

    Note: Violations to Catalog Values and Single Property Expression Rules are not reflected by the Chat Channel.
  • Cross-Data Class Expression and Multiple Properties Expression Rules (see documentation) are not enforced and error messages are not reflected by the Chat Channel.

  • The Start Subprocess Action available on the Controls tab is ignored, accordingly the 'onsubprocessstart' event available on the Action tab of the Chat Channel Screen Component cannot be triggered.

  • Collection Controls defined on the Controls tab are not rendered by the Chat Channel. This includes multi-selections (represented by a Checkbox List or Multiple Selection Field) that are modeled using a Collection Control and a Catalog Values Rule.

  • Data Class Controls are supported and rendered with the limitations on certain data types outlined in the final item of this list.

  • If the nested properties of a Data Class Control include a Data Class, ensure it is properly initialized so that this Data Class is rendered correctly, for example with (replace DataClassName, NestedDataClassName, and NestedDataClassType with the actual names):

    DataClassName := NewObject(DataClassName);
    $a.NestedDataClassName := NewObject(NestedDataClassType);
    Return $a;
  • When using Data Class Controls, use the Unfold option to gain access to each individual Data Control. This allows you to customize the Extended Label property with a text (question) which is suited to the Chat Channel environment.

  • Primitive Controls using the following data types are supported by the Chat Channel:

    • Date
    • String
    • Money (nullify)
    • Double (nullify)
    • Float (nullify)
    • Integer (nullify)
    • Long (nullify)

    Primitive Controls using other data types such as Boolean are not supported by the Chat Channel.

    Supported data types for which "nullify" is indicated in the above list are only rendered by the Chat Channel if the data is "nullified". This requires an additional action, as Appway initializes these data types as non-null values by default (e.g. 0 or 0.0). To nullify these values, one possibility is to go to the Variables tab of the Data Logic Business Object and define an appropriate Default Expression, for example:
    • For a Data Class (replace DataClassName with the actual name):
      DataClassName $a := NewObject(DataClassName);
      $a.quantity := null;
      Return $a;
    • For a Primitive Type:
      null
© 2026 Appway AG. All Rights Reserved