🔒 Guided

Pre-launch preview. Authorised access only.

Incorrect code

Guided by A Guide to Cloud
Explore AB-900 AI-901
Guided PL-400 Domain 4
Domain 4 — Module 2 of 4 50%
12 of 26 overall

PL-400 Study Guide

Domain 1: Create a Technical Design

  • Solution Architecture: What Goes Where Free
  • Security by Design: Auth, Roles & DLP Free
  • Designing UX Components: Canvas, PCF & Client Scripts Free
  • Designing Platform Extensions: Connectors, Plug-ins & APIs Free
  • Integration & Automation Blueprints Free

Domain 2: Build Power Platform Solutions

  • Environment Setup & Security Troubleshooting
  • Solutions & Layers: ALM Foundations
  • CI/CD Pipelines for Power Platform

Domain 3: Implement Power Apps Improvements

  • Advanced Power Fx & Canvas Components
  • Troubleshoot & Optimise Apps

Domain 4: Extend the User Experience

  • Client Scripting: Form Events & the Client API
  • Commands, Buttons & Custom Page Navigation
  • PCF Components: Build & Lifecycle
  • PCF Components: Package, Deploy & Advanced Features

Domain 5: Extend the Platform

  • The Plug-in Pipeline: How Dataverse Processes Events Free
  • Writing Plug-ins: Business Logic, Service & Registration
  • Custom APIs & Business Events
  • Custom Connectors: OpenAPI & Authentication
  • Custom Connectors: Azure, Policies & Code
  • Dataverse APIs: Web API & Organisation Service
  • Azure Functions for Power Platform
  • Cloud Flows: Dataverse Triggers & Expressions
  • Cloud Flows: Security, Errors & Child Flows

Domain 6: Develop Integrations

  • Publishing Dataverse Events
  • Service Endpoints: Webhooks, Service Bus & Event Hub
  • Data Sync: Change Tracking, Alternate Keys & Upsert

PL-400 Study Guide

Domain 1: Create a Technical Design

  • Solution Architecture: What Goes Where Free
  • Security by Design: Auth, Roles & DLP Free
  • Designing UX Components: Canvas, PCF & Client Scripts Free
  • Designing Platform Extensions: Connectors, Plug-ins & APIs Free
  • Integration & Automation Blueprints Free

Domain 2: Build Power Platform Solutions

  • Environment Setup & Security Troubleshooting
  • Solutions & Layers: ALM Foundations
  • CI/CD Pipelines for Power Platform

Domain 3: Implement Power Apps Improvements

  • Advanced Power Fx & Canvas Components
  • Troubleshoot & Optimise Apps

Domain 4: Extend the User Experience

  • Client Scripting: Form Events & the Client API
  • Commands, Buttons & Custom Page Navigation
  • PCF Components: Build & Lifecycle
  • PCF Components: Package, Deploy & Advanced Features

Domain 5: Extend the Platform

  • The Plug-in Pipeline: How Dataverse Processes Events Free
  • Writing Plug-ins: Business Logic, Service & Registration
  • Custom APIs & Business Events
  • Custom Connectors: OpenAPI & Authentication
  • Custom Connectors: Azure, Policies & Code
  • Dataverse APIs: Web API & Organisation Service
  • Azure Functions for Power Platform
  • Cloud Flows: Dataverse Triggers & Expressions
  • Cloud Flows: Security, Errors & Child Flows

Domain 6: Develop Integrations

  • Publishing Dataverse Events
  • Service Endpoints: Webhooks, Service Bus & Event Hub
  • Data Sync: Change Tracking, Alternate Keys & Upsert
Domain 4: Extend the User Experience Premium ⏱ ~11 min read

Commands, Buttons & Custom Page Navigation

Customise the model-driven app command bar with Power Fx and JavaScript. Add custom buttons, configure visibility rules, and navigate users to custom pages.

Making apps your own

☕ Simple explanation

Think of the command bar as a restaurant menu board.

The standard menu shows common items. But you want to add a “Daily Special” button that only appears on Fridays, a “VIP Order” button that only managers can see, and a “Feedback” button that opens a custom form. Command bar customisation lets you do exactly this — add, modify, and conditionally show buttons in model-driven apps.

Custom pages are like hidden rooms in the restaurant. Navigation sends users to canvas-app-like experiences embedded within the model-driven app — perfect for wizards, dashboards, or specialised forms that go beyond standard form layouts.

The command bar (formerly ribbon) in model-driven apps can be customised using two approaches: Power Fx commanding (low-code, modern, recommended) and JavaScript commanding (classic, more powerful, used for complex scenarios). Power Fx commands use the modern command designer with formulas for visibility and actions. JavaScript commands use web resources and XML-based ribbon definitions.

Custom pages are canvas-app-style pages that run inside model-driven apps. They enable rich, custom UI experiences while maintaining the model-driven app’s navigation and security context. Navigation to custom pages uses the Client API navigateTo function or Power Fx Navigate() in commanding.

Two ways to customise commands

Use Power Fx commanding for new projects unless you need JavaScript-level control
FeaturePower Fx Commanding (Modern)JavaScript Commanding (Classic)
LanguagePower Fx formulasJavaScript + XML ribbon definitions
EditorModern command designer (visual)Ribbon Workbench or raw XML
Visibility rulesPower Fx Visible propertyEnableRules/DisplayRules in XML
ActionsPower Fx OnSelect (Navigate, Patch, etc.)JavaScript function calls
Context accessSelf.Selected.Item, Self.Selected.AllItemsPrimaryControl (formContext), SelectedControl
Custom pagesNavigate(CustomPage) directlyXrm.Navigation.navigateTo()
Complexity limitSimple to medium actionsAny complexity — full JavaScript
Recommended forNew development, simple commandsComplex logic, legacy systems, advanced scenarios

Power Fx commanding example

A “Generate Report” button that only appears when the record status is Active:

// Visible property (controls when the button shows)
Self.Selected.Item.Status = "Active"

// OnSelect (what happens when clicked)
Navigate(ReportGeneratorPage, {CaseId: Self.Selected.Item.CaseId})

JavaScript commanding example

The same button using JavaScript:

// Visibility rule — registered in ribbon XML
function isRecordActive(primaryControl) {
    var formContext = primaryControl;
    var status = formContext.getAttribute("statuscode").getValue();
    return status === 1; // Active
}

// Action — registered in ribbon XML
function generateReport(primaryControl) {
    var formContext = primaryControl;
    var caseId = formContext.data.entity.getId();
    
    Xrm.Navigation.navigateTo(
        { pageType: "custom", name: "new_reportgenerator", recordId: caseId },
        { target: 2, width: 800, height: 600, position: 1 } // Dialog
    );
}

Navigating to custom pages

Custom pages are canvas-app-like experiences embedded in model-driven apps. They are ideal for:

  • Wizards — multi-step forms that guide users through a process
  • Dashboards — visual summaries with charts and KPIs
  • Complex forms — layouts that go beyond what standard model-driven forms offer

Navigation options

MethodOpens AsUse Case
navigateTo with target: 1Full page (replaces current view)Main workflow pages
navigateTo with target: 2Dialog (centered popup)Quick actions, wizards, confirmations
navigateTo with target: 2, position: 2Side panelReference information while working on a form
Power Fx Navigate()Inline (within model-driven nav)From Power Fx commanding
💡 Scenario: Kai builds a shipment wizard

Kai creates a “New Shipment” command button on the Shipment table’s main grid. When clicked, it opens a custom page as a dialog — a 3-step wizard:

Step 1: Select destination (dropdown populated from Dataverse) Step 2: Add package details (dimensions, weight, special handling) Step 3: Review and confirm

The wizard is built as a canvas custom page with navigation between screens. When the user confirms, the page creates the Shipment record via Patch() and closes the dialog.

Why a custom page? Standard model-driven forms do not support multi-step wizards. Custom pages provide the canvas app flexibility within the model-driven app context.

Question

What is Power Fx commanding in model-driven apps?

Click or press Enter to reveal answer

Answer

A modern approach to customising the command bar using Power Fx formulas instead of JavaScript. You define button visibility (Visible property), actions (OnSelect), and context (Self.Selected.Item) using Power Fx. It is simpler than JavaScript commanding and recommended for new development.

Click to flip back

Question

What is a custom page in a model-driven app?

Click or press Enter to reveal answer

Answer

A custom page is a canvas-app-style page that runs inside a model-driven app. It provides flexible UI capabilities (galleries, custom layouts, Power Fx logic) while inheriting the model-driven app's navigation and security context. Navigate to it using Xrm.Navigation.navigateTo() or Power Fx Navigate().

Click to flip back

Question

How do you open a custom page as a dialog from JavaScript?

Click or press Enter to reveal answer

Answer

Use Xrm.Navigation.navigateTo({ pageType: 'custom', name: 'page_unique_name' }, { target: 2, width: 800, height: 600, position: 1 }). Target 2 opens as a dialog, position 1 centres it. You can pass recordId as a parameter for context.

Click to flip back

Knowledge Check

A developer needs to add a 'Quick View' button to a model-driven app that opens a summary panel on the right side of the screen without navigating away from the current form. Which approach is correct?

🎬 Video coming soon

Next up: PCF Components — building your first code component with TypeScript, understanding the lifecycle, and configuring the manifest.

← Previous

Client Scripting: Form Events & the Client API

Next →

PCF Components: Build & Lifecycle

Guided

I learn, I simplify, I share.

A Guide to Cloud YouTube Feedback

© 2026 Sutheesh. All rights reserved.

Guided is an independent study resource and is not affiliated with, endorsed by, or officially connected to Microsoft. Microsoft, Azure, and related trademarks are property of Microsoft Corporation. Always verify information against Microsoft Learn.