> ## Content Index
> Fetch the complete content index at: https://nolongerset.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# VIDEO: Modern On Off Buttons in Access
- URL: https://nolongerset.com/modern-on-off-video/
- Published: 2022-07-27T19:36:44.000Z
- Updated: 2026-05-08T12:56:02.000Z
- Description: I recorded a YouTube video that demonstrates how to implement the Modern On/Off button feature that I wrote about yesterday.
- Author: Mike Wolfe
- Tags: Video, #Import 2026-05-20 02:59

I recorded a [companion video](https://www.youtube.com/watch?v=zdy%5FyKHMdCY) to go with [yesterday's article](https://nolongerset.com/modern-on-off/) about creating modern On/Off buttons in Microsoft Access.

## Support for Continuous Forms

One of the problems with the solution I wrote about yesterday is that it did not work so well for continuous forms. 

Here's a screenshot of the original approach to see what I mean:

![](https://storage.ghost.io/c/eb/d7/ebd732c1-5f03-4f07-b386-5d08557e15c9/content/images/2022/07/image-40.png)

To address this issue, I added an optional parameter to the `FormatToggle()` function to hide the disc icon. When the disc icon is hidden, the border also remains blue for both the ON and OFF positions. 

Here's the updated look:

![](https://storage.ghost.io/c/eb/d7/ebd732c1-5f03-4f07-b386-5d08557e15c9/content/images/2022/07/image-41.png)

It's not as nice as the one with the circle that slides from left to right, but it's still easier to read at a glance than a checkbox. I'm not sure how often I would use this feature in a continuous form, but at least now it's an option.

## The (Improved) Code

This fix required no changes to the `CreateModernOnOff()` routine that I wrote about yesterday. Refer to [that article](https://nolongerset.com/modern-on-off/) to get the code for `CreateModernOnOff()`.

The following code is a complete (backwards-compatible) replacement for the `FormatToggle()` function from yesterday's article:

```vba
'Companion function to CreateModernOnOff() procedure (https://nolongerset.com/modern-on-off/)
'Source    : https://nolongerset.com/modern-on-off-video/
'This is version 2 of the FormatToggle() function
'	- added Optional ShowCaption parameter to better support continuous forms
Function FormatToggle(ToggleBtn As ToggleButton, _
                      Optional ShowCaption As Boolean = True)
    Const Buffer As Long = 2
    With ToggleBtn
        If ShowCaption Then
            If .Value Then
                'When button is ON, leading spaces force
                '   disc icon to the right
                .Caption = Space(Buffer) & "l"
                .BorderColor = vbBlue
            Else
                'When button is OFF, trailing spaces force
                '   disc icon to the left
                .Caption = "l" & Space(Buffer)
                .BorderColor = vbBlack
            End If
        Else
            .Caption = ""
            .BorderColor = vbBlue
        End If
    End With
End Function
```

### Referenced articles

[Modern On/Off Button in AccessLeave those boring checkboxes behind and move into the 21st century with these modern on-off switches for Microsoft Access. Very little code required!![](https://nolongerset.com/favicon.png)No Longer SetMike Wolfe![](https://storage.ghost.io/c/eb/d7/ebd732c1-5f03-4f07-b386-5d08557e15c9/content/images/2022/07/Modern-OnOff-Buttons-in-Access.png)](https://nolongerset.com/modern-on-off/)