This is a migrated thread and some comments may be shown as answers.

Custom editor with display Text

1 Answer 107 Views
PropertyGrid
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 19 Aug 2019, 08:27 PM

Hi -

I want to create a custom editor that has just a textbox and a button.  The button will launch a form that allows me to select an object of type Product.  When I click OK on the form, I want to display the Name property of the object (in the text box in the grid, as read only), but I want the VALUE to be a different property, in this case ID.

My object looks like:

class Product

{

   string Name;

   Guid ID;

}

How can this be achieved?

 

Thanks in advance!

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 20 Aug 2019, 06:27 AM
Hi John,

To achieve this you can create a custom editor with a RadButtonTextBoxElement. You can start the new form directly from the editor class. I have attached a sample project that shows this. 

I hope this helps. Should you have any other questions, do not hesitate to ask.

Regards,
Dimitar
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.
Tags
PropertyGrid
Asked by
John
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Share this question
or