How to add WPF-UserControl to RadElement

2 posts, 0 answers
  1. Tomek
    Tomek avatar
    1 posts
    Member since:
    Mar 2020

    Posted 04 Mar 2020 Link to this post

    Hallo,

    I have Winforms Application.

    I created WPF-UserControl.

    I'm trying to add this WPF-UserControl (per elementHost) to one of RadElement in my Winforms Form.

    It could be RadPanelElement or my custom class extending RadElement.

    Is it possible, and if it is possible how can i add, place WPF-UserControl on RadElement?

    Or how can i prepare my custom radElement which will show WPF-UserControl?

     

     

  2. Nadya
    Admin
    Nadya avatar
    509 posts

    Posted 06 Mar 2020 Link to this post

    Hello Tomek,

    You can create a custom control by using RadHostItem class which allows you to add controls to RadElements. More information and example is available here: https://docs.telerik.com/devtools/winforms/telerik-presentation-framework/elements/use-control-inside-an-element#use-controls-inside-an-element

    Note, although it is possible to host an entire user control in RadHostItem, it is not recommended to do so in cases with complex controls.

    I hope this information helps.

    Regards,
    Nadya
    Progress Telerik

    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top