Loading...

clicking link on info message X++ to Open form

clicking link on info message X++ to Open form

 Message::AddAction() method can be used to embed an action within a message sent to the message bar. This method supports adding a single action that is associated with a display or action menu item, which is then visualized as a link button, redirecting users directly to the form with the correct record selected. Here's how it can be used.



public static void pushNotification(str  NotificationMsg, str actionText,LedgerJournalTable journalTable)
{
    MenuItemMessageAction actionData = new MenuItemMessageAction();
    actionData.MenuItemName(menuItemDisplayStr(LedgerJournalTable));
    actionData.TableName(tableStr(LedgerJournalTable));
    actionData.RecId(journalTable.RecId);
    
    str jsonData = FormJsonSerializer::serializeClass(actionData);
 
    int64 messageId = Message::AddAction(MessageSeverity::Informational,NotificationMsg ,actionText, MessageActionType::DisplayMenuItem, jsonData);
} 

Muhammad Aamir Hanif Reference 


Published on:

Learn more
Sherif Fayed
Sherif Fayed

Share post:

Related posts

Dynamics 365 CE vs Finance & Operations: Which Microsoft Dynamics 365 Career Path Should You Choose in 2026?

Introduction Microsoft Dynamics 365 is one of the world’s leading enterprise business application platforms, offering specialized soluti...

5 days ago

Overview Quality Management in Microsoft Dynamics 365 Finance & Operations – Part 1

Why Every Manufacturing Business Needs Quality Management Overview Why Every Manufacturing Business Needs Quality Management Imagine walking i...

20 days ago

X++ Show Cross-Reference With Read/Write field reference

New release of TRUDUtilsD365 Developer Add-in that includes an advanced Cross-references form, allowing you to see the actual X++ code and det...

4 months ago

Support Parallel Processing for Archive Jobs in Dynamics 365 Finance and Operations

We’re pleased to introduce a new capability for Dynamics 365 Finance and Operations archive with Dataverse long-term retention: parallel proce...

4 months ago

D365FO License usage log utility

Learn how the new D365FO licensing model works and discover an open-source X++ utility to monitor actual user activity and optimize your licen...

4 months ago

Implement Service-based integration in D365FO

This blog post describes how to implement a synchronous integration with D365FO by creating a service using the External Integration framework...

5 months ago

Sync data from Dynamics 365 Finance & Operations Azure SQL Database (Tier2) to local SQL Server (AxDB)

A new utility to synchronize data from D365FO cloud environments to local AxDB, featuring incremental sync and smart strategies.

6 months ago

Action ‘Update_a_record’ failed: An error has occurred. No resources were found when selecting for update – Fixing Cross-Company Update Issues in Finance & Operations Using Dataverse Virtual Entities (Power Automate)

Recently, while trying to update the Projects table in Finance & Operations using the Fin & Ops Apps actions in Power Automate, we ran...

8 months ago

Simplifying License Management for Dynamics 365 Finance and Operations: Improved User License Validation

Microsoft is updating the timeline for in-app notifications and per-user license validation to give customers more time to prepare. To enable ...

10 months ago
Stay up to date with latest Microsoft Dynamics 365 and Power Platform news!
* Yes, I agree to the privacy policy