Share via

Display message for 2 seconds, then clear itself

Peter Corbally 40 Reputation points
2026-03-24T23:54:48.6533333+00:00

I want display a message for 2 seconds, then have the message disappear without having to press ok

Microsoft 365 and Office | Excel | For home | Windows
0 comments No comments

Answer accepted by question author
  1. Q&A Assist
    2026-03-24T23:54:59.3533333+00:00
    AI generated content. This question contains an answer created with AI from Q&A Assist. Learn more

    Excel itself does not provide a built-in way to show a temporary message that automatically disappears after a fixed time without user interaction. However, similar behavior can be implemented in other Microsoft technologies using their notification or message APIs.

    Examples from other platforms:

    1. Power Automate for desktop – Display message action
      • The Display message action can show a message box and close it automatically after a timeout when Close message box automatically is enabled and Timeout is set (in seconds). The flow then continues as if the default button was pressed.
      • This matches the requirement: a message appears, waits for a specified duration, and then closes without user input.
    2. .NET MAUI CommunityToolkit – Toast notifications
      • A Toast can be created with Toast.Make(text, duration, fontSize) and shown with await toast.Show(token);.
      • The ToastDuration enum supports:
        • Short – 2 seconds
        • Long – 3.5 seconds
      • This displays a non-blocking notification that automatically disappears after the chosen duration.
    3. GameKit (iOS via .NET bindings) – GKNotificationBanner
      • GKNotificationBanner.ShowAsync(string? title, string? message, double durationSeconds) displays a banner for durationSeconds and then hides it automatically.
    4. Windows system notification duration
      • Windows pop-up notification duration is controlled by the SPI_GETMESSAGEDURATION system parameter, which can be adjusted (for accessibility) so that notification toasts stay visible longer before disappearing automatically.

    To achieve similar behavior around Excel, consider:

    • Using Power Automate for desktop to display and auto-close a message while automating Excel tasks.
    • Using a companion app (for example, a .NET MAUI app or another client) to show toast-style notifications for Excel-related events, with a 2-second duration.

    References:

    ](https://learn.microsoft.com/dotnet/api/gamekit.gknotificationbanner.showasync?view=net-ios-26.2-10.0)

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.