web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested Answer

Issue with the Text Input (Modern Control) in Canvas Apps

(4) ShareShare
ReportReport
Posted on by 2,116
Hi Team,
 
We've observed that the new "Text Input" control in canvas apps or custom pages doesn't support the "OnSelect" property, which was previously available in the classic "Text Box" control.
 
While the modern control does include the "OnChange" property, but our requirement is to trigger logic as soon as the user clicks or focuses on the text box.
 
Is there any way to replicate this behavior in the modern control, similar to how the "OnSelect" event worked in the classic control?
 
Any kind of help would be greatly appreciated.
 
Thank you
Categories:
I have the same question (0)
  • Suggested answer
    Holly Huffman Profile Picture
    6,554 Super User 2026 Season 1 on at
    Good morning, afternoon, or evening depending on your location!
     
    The modern "Text Input" control in Power Apps does not support the "OnSelect" property, as you've noted. However, you can replicate similar behavior using alternative approaches.
    1. Use the OnChange Property:
    • While it doesn't trigger logic on focus or click, you can use the OnChange property to execute actions when the user modifies the text. This is the closest built-in functionality available.
    2. Overlay a Transparent Button:
    • Place a transparent button over the text input control. Set the button's OnSelect property to trigger your desired logic. When the user clicks the text box, they'll actually be interacting with the button.
    3. Focus Detection with Timer Control:
    • Use a timer control to detect when the text input gains focus. Combine this with the FocusedBorderColor property to visually indicate focus and trigger logic indirectly.
    4. Custom Component:
    • Create a custom component that combines the modern text input control with additional functionality, such as focus detection or click events.
     
    Hope this is helpful :)
  • Suggested answer
    Inogic Profile Picture
    756 on at
    Hi,
     
    There are a few creative workarounds you can use to replicate “OnSelect” or “OnFocus” behavior in modern Text Input controls. Follow the below steps.

    1. Add a Timer control
    • Set Duration to something small, like 10
    • Set Repeat to false
    • Set AutoStart to false
    • Set Visible to false (optional)

    2. Add a variable to detect focus
    • In your screen's OnVisible, initialize:
                   
    Set(varFocused, false); Set(varShowOverlay, true)
    3. Add a transparent Rectangle over the Text Input
    • Drag the Rectangle to cover the Text Input exactly (or slightly larger if needed).
    • Resize it to match the size of Text Input.
    • This will simulate OnSelect
    • Set Fill to RGBA(0, 0, 0, 0), Visible to varShowOverlay, BorderThickness to 0, and ensure it's on top of the Text Input
    • Right-click the rectangle Reorder Bring to Front
                  4. OnSelect of this Rectangle:
          Set(varFocused, true); Timer1.Start=true; Set(varShowOverlay, false);

                 5. In Timer1.OnTimerEnd:
          SetFocus(Text Input)

    Now you're programmatically focusing the input and can add any logic in OnSelect property of Rectangle.

    Hope this helps.
     
    Thanks!
    Inogic

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
11manish Profile Picture

11manish 154

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 73 Super User 2026 Season 1

#3
ManoVerse Profile Picture

ManoVerse 55 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans