Add a Remove Button in ChatUI's messages
Environment
Product Version | Product | Author |
---|---|---|
2019.2.508 | RadChat for WinForms | Desislava Yordanova |
Description
This article demonstrates how to remove a message in RadChat by adding a button in each message.
Solution
The ChatFactory class provides means for changing the default visual elements and data items in the RadChat control. If you need to customize any of the Chat UI's elements or items you can create a descendant of the ChatFactory class, override the corresponding methods and replace the default elements with custom ones.
To achieve the illustrated design, we will create a derivative of TextMessageItemElement and insert a RadButtonElement that will remove the associated message: