---
id: post/yzhums-com/74473
type: post
title: "Dynamics 365 Business Central: Formatting Boolean Values (Yes/No, true/false, and 1/0)"
summary: Boolean fields in Business Central display as checkboxes by default, but converting them to text for pages or reports requires specific methods. The post demonstrates how to use ToText() and Format() functions with different parameters to display Boolean values as Yes/No, true/false, or 1/0.
tier: community
language: en
tags:
  - boolean
  - formatting
  - data types
  - al language
  - best practices
system: development
review:
  state: reviewed
  by: opus
  at: "2026-10-26T06:39:51.430Z"
  flags: []
generated:
  at: "2026-10-26T05:51:10.938Z"
  pipeline: 0.2.0
  prompts:
    extract-post: 1
  input_hash: 8d9a366a309cb01aee6cf5dcd00ad9d67e194bf5093789c22224fc493d059b2c
evidence:
  - kind: blog
    url: https://yzhums.com/74473/
    title: "Dynamics 365 Business Central: Formatting Boolean Values (Yes/No, true/false, and 1/0)"
    date: "2026-07-07"
    commit: null
    t: null
    quote: null
  - kind: blog
    url: https://yzhums.com/74473/
    title: "Dynamics 365 Business Central: Formatting Boolean Values (Yes/No, true/false, and 1/0)"
    date: "2026-07-07"
    commit: null
    t: null
    quote: Boolean field in the database is automatically rendered as a Checkbox/Toggle on the page (UI) by default
  - kind: blog
    url: https://yzhums.com/74473/
    title: "Dynamics 365 Business Central: Formatting Boolean Values (Yes/No, true/false, and 1/0)"
    date: "2026-07-07"
    commit: null
    t: null
    quote: Since a Boolean is already a truth value, do not compare it to true or false unnecessarily.
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
post_id: "74473"
source_id: yzhums-com
source_name: Dynamics 365 Lab - Yun Zhu
url: https://yzhums.com/74473/
published_at: "2026-07-07T00:30:28.000Z"
author: Yun Zhu
full_text: false
words: 283
quotes:
  - text: Boolean field in the database is automatically rendered as a Checkbox/Toggle on the page (UI) by default
    why_it_matters: Explains default UI behavior for Boolean fields, establishing why conversion methods are needed
  - text: Since a Boolean is already a truth value, do not compare it to true or false unnecessarily.
    why_it_matters: Core best practice for writing cleaner, more readable AL code
code_objects_mentioned:
  - other CustomerListExt
systems:
  - development
versions_mentioned: []
preview:
  embeddable: true
  frame_url: null
  image: https://yzhums.com/wp-content/uploads/2026/07/Snipaste_2026-07-06_14-15-11.png
  image_alt: null
  image_w: null
  image_h: null
  site_name: Dynamics 365 Lab
  favicon: https://yzhums.com/wp-content/uploads/2020/08/cropped-logo-3-32x32.png
  probed_at: "2026-10-26T06:03:16.316Z"
---

# Dynamics 365 Business Central: Formatting Boolean Values (Yes/No, true/false, and 1/0)

[Read the post](https://yzhums.com/74473/) · Dynamics 365 Lab - Yun Zhu (Yun Zhu, MVP) · 2026-07-07 · 283 words · tier community · reviewed (checked by Opus)

> Boolean fields in Business Central display as checkboxes by default, but converting them to text for pages or reports requires specific methods. The post demonstrates how to use ToText() and Format() functions with different parameters to display Boolean values as Yes/No, true/false, or 1/0.

## Key points

- Boolean fields automatically render as toggles on UI, but need conversion for text display in reports
- Use ToText() method or Format() function with parameter combinations (0,9) and (0,2) to convert Boolean to text
- Follow naming conventions using prefixes like Is, Has, or Allow for Boolean variables to improve code readability
- Avoid comparing Boolean values to true/false unnecessarily; use if IsPosted then instead of if IsPosted = true then

## Quotes

- "Boolean field in the database is automatically rendered as a Checkbox/Toggle on the page (UI) by default" (Explains default UI behavior for Boolean fields, establishing why conversion methods are needed)
- "Since a Boolean is already a truth value, do not compare it to true or false unnecessarily." (Core best practice for writing cleaner, more readable AL code)

## AL objects mentioned

As named in the post. A name that matches one object page by exact type and name links to it; the others stay as named.

- other "CustomerListExt"

## Context

- Features: Boolean data type, Format function, ToText method, checkbox rendering, text conversion

Source: Dynamics 365 Lab - Yun Zhu, community blog. Summary, key points and quotes are derived (CONTENT-NOTICE.md); read the original for the full text.
