{"title":"Creating cues and action tiles on role centers","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/devenv-cues-action-tiles/","by":"JOP-AL","license":"Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/devenv-cues-action-tiles, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact.","credit":"Microsoft Corporation, CC BY 4.0","origin":"https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/devenv-cues-action-tiles","source":{"name":"Business Central developer and IT pro docs","repo":"https://github.com/MicrosoftDocs/dynamics365smb-devitpro-pb","commit":"828b6ee72fcd75755627cd6011f3d20899217ab2","date":"2026-11-19"},"checked":"2026-11-19","description":"Learn how to create Business Central cues and action tiles with AL, choose layouts, calculate cue values, and configure tile actions and images.","date":"2024-07-03","meta":{"topic":"how-to"},"outline":[{"level":1,"title":"Creating cues and action tiles on role centers","slug":"creating-cues-and-action-tiles-on-role-centers","at":0,"chars":8094},{"level":2,"title":"Designing numeric cues","slug":"designing-numeric-cues","at":561,"chars":5555},{"level":3,"title":"Normal and wide layouts","slug":"normal-and-wide-layouts","at":859,"chars":963},{"level":3,"title":"Supported cue data types","slug":"supported-cue-data-types","at":1822,"chars":105},{"level":3,"title":"FlowFields versus normal fields","slug":"flowfields-versus-normal-fields","at":1927,"chars":378},{"level":3,"title":"Creating a table-backed cue","slug":"creating-a-table-backed-cue","at":2305,"chars":346},{"level":3,"title":"Create a table for cue data","slug":"create-a-table-for-cue-data","at":2651,"chars":1318},{"level":4,"title":"Cue data table example","slug":"cue-data-table-example","at":3373,"chars":596},{"level":3,"title":"Add cues to a page object","slug":"add-cues-to-a-page-object","at":3969,"chars":2147},{"level":4,"title":"Cue page example","slug":"cue-page-example","at":5219,"chars":897},{"level":2,"title":"Designing action tiles","slug":"designing-action-tiles","at":6116,"chars":1877},{"level":3,"title":"Create an action tile","slug":"create-an-action-tile","at":6477,"chars":945},{"level":4,"title":"Action tile example","slug":"action-tile-example","at":6882,"chars":540},{"level":3,"title":"Styling an action tile","slug":"styling-an-action-tile","at":7422,"chars":571},{"level":2,"title":"Related information","slug":"related-information","at":7993,"chars":101}],"text":"# Creating cues and action tiles on role centers\nUse cues to display business data and action tiles to start tasks on role centers. This article explains how to create both with AL.\nThe following illustration identifies cue groups, drill-down links, captions, and action tiles. Their appearance can vary by version and configuration.\n![Annotated role center cues showing normal and wide layouts, drill-down links, and action tiles.]\n> NOTE\n> Page extensions don't support adding actions to existing cue groups or modifying or moving existing cue group actions.\n## Designing numeric cues\nA cue displays business data, such as the number of open sales invoices. You can configure a cue to drill down to records, open another page, or run code. A page field in a cuegroup displays the value. The following example uses table fields for raw or calculated values.\n### Normal and wide layouts\nThere are two layout options for cues: normal and wide.\n The normal layout displays cues as tiles. Groups fill the available workspace width, so multiple groups can appear side by side.\n The wide layout emphasizes cues with large values, such as monetary amounts. You can interleave wide and normal cue groups. Place wide groups before normal groups when you want to emphasize them. Wide cues retain their wide styling wherever they appear. Depending on the number of visible cues, the desktop client can add dividers between groups and expand their containing CardPart to the full workspace width. Set the properties/devenv-cuegrouplayout-property to Wide.\n> NOTE\n> The wide cue layout is supported in the desktop web client. Phone and tablet clients use their mobile cue layout.\n> The properties/devenv-caption-property and properties/devenv-captionml-property properties of the cuegroup control are ignored when the layout is wide.\n### Supported cue data types\nCues support Integer and Decimal values. Other data types aren't supported.\n### FlowFields versus normal fields\nA table-backed cue can use a FlowField or Normal field.\n For a FlowField, define the calculation in the properties/devenv-calcformula-property.\n For a Normal field, calculate the value in an AL trigger or method.\n  Unlike a FlowField calculation over tables, AL code can populate a Normal field with data from other objects, such as queries.\n### Creating a table-backed cue\nThis table-backed example uses:\n A table with a field for each cue value.\n A page that displays the values in cue fields.\n Logic that calculates the values, using a FlowField formula or AL code and objects such as queries and codeunits.\n> NOTE\n> The examples count open sales invoices in the `Sales Header` table.\n### Create a table for cue data\nCreate a table with fields for the cue values.\n1. Create a table object or use an existing one.\n2. Add a field for each cue in this table-backed example.\n  Use Integer or Decimal as the field type.\n  Set the properties/devenv-fieldclass-property to FlowField or Normal.\n  For a FlowField, set the properties/devenv-calcformula-property to calculate the value.\n3. Define a primary key using a Normal field. For a cue table that holds one record, you can use a Code field with a blank value. FlowFields aren't stored as data fields, so a table containing only cue FlowFields still needs this stored key field.\nLearn more about field properties in AL properties<properties/devenv-properties>.\n#### Cue data table example\n```al\nusing Microsoft.Sales.Document;\n\ntable 50100 SalesInvoiceCueTable\n{\n    DataClassification = ToBeClassified;\n\n    fields\n    {\n        field(1; PrimaryKey; Code[250])\n        {\n            DataClassification = ToBeClassified;\n        }\n        field(2; SalesInvoicesOpen; Integer)\n        {\n            FieldClass = FlowField;\n            CalcFormula = count(\"Sales Header\" where(\"Document Type\" = filter(Invoice), Status = filter(Open)));\n        }\n    }\n\n    keys\n    {\n        key(PK; PrimaryKey)\n        {\n            Clustered = true;\n        }\n    }\n}\n```\n### Add cues to a page object\nCreate a page that uses the cue table and displays its fields. Typically, you use a CardPart page embedded in a role center. Arrange the cues in groups with captions. After creating the page, add it as a part of the target role center. Learn more about adding the cue page to a role center in Simple role center code example<devenv-simple-role-center-example>.\n1. Create a page object that has the properties/devenv-sourcetable-property set to the cue data table.\n2. Add a cuegroup control.\n3. Under the cuegroup control, for each cue that you want to display, add a field control.\n4. Set the field's properties/devenv-caption-property or properties/devenv-captionml-property to specify the label that appears on the cue. These properties also specify the heading in the drill-down page.\n> NOTE\n> You can't use the properties/devenv-captionclass-property for this purpose.\n5. To use the wide layout, set the CuegroupLayout property to Wide. Repeat steps 2-4 to add more groups.\n6. Initialize the cue fields.\n For example, add the following code to the triggers-auto/page/devenv-onopenpage-page-trigger:\n ```al\n     Rec.Reset();\n     if not Rec.Get() then begin\n         Rec.Init();\n         Rec.Insert();\n     end;\n ```\n#### Cue page example\n```al\nusing Microsoft.Sales.Document;\n\npage 50105 SalesInvoiceCuePage\n{\n    PageType = CardPart;\n    SourceTable = SalesInvoiceCueTable;\n    Caption = 'Sales Invoices Cues';\n    layout\n    {\n        area(content)\n        {\n            cuegroup(SalesCueContainer)\n            {\n                Caption = 'Sales Invoices';\n                // CuegroupLayout = Wide;\n                field(SalesCue; Rec.SalesInvoicesOpen)\n                {\n                    ApplicationArea = All;\n                    Caption = 'Open';\n                    ToolTip = 'Specifies the number of open sales invoices.';\n                    DrillDownPageId = \"Sales Invoice List\";\n                }\n            }\n        }\n    }\n\n    trigger OnOpenPage();\n    begin\n        Rec.Reset();\n        if not Rec.Get() then begin\n            Rec.Init();\n            Rec.Insert();\n        end;\n    end;\n}\n```\n## Designing action tiles\nAction tiles let users start tasks from the role center. An action tile can open a page, start a video, open a resource or URL, or run code. Action tiles are arranged like cues that use the normal layout.\nGroup action tiles under a common caption with a cuegroup control. Add actions, rather than fields, to the group's actions block.\n### Create an action tile\n1. Develop or locate the functionality for the action tile.\n For example, create the page that the tile opens or the AL code it runs.\n2. Add a cuegroup control in the page layout where you want the action group.\n3. Inside the cue group's actions block, add an action control. To open a page, set its properties/devenv-runobject-property. To run AL code, add an OnAction trigger.\n#### Action tile example\nThe following fragment adds a tile that opens the Sales Invoice page. Place it in the page layout's content area. The surrounding AL file needs the Microsoft.Sales.Document namespace in scope, as in the cue page example.\n```al\ncuegroup(SalesActionontainer)\n{\n    Caption = 'New Sales Invoice';\n\n    actions\n    {\n\n        action(ActionName)\n        {\n            RunObject = page \"Sales Invoice\";\n            Image = TileNew;\n            trigger OnAction()\n            begin\n\n            end;\n        }\n    }\n}\n```\n### Styling an action tile\nUse the properties/devenv-image-property on the action control to change a tile's appearance. Supported values start with Tile, such as TileNew and TileYellow:\n A supported `Tile<Color>` value selects a circle icon and the specified background color. For example, TileBlue displays a circle on a blue background.\n A supported `Tile<Picture>` value selects an icon on a neutral background. For example, TileCamera displays a camera icon.\n> NOTE\n> If the value isn't recognized, the tile displays the default circle icon on a neutral background.\n## Related information\ndevenv-flowfields\ndevenv-page-object\ndevenv-pages-overview\ndevenv-table-object"}