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

Text area as an items.editor

2 Answers 489 Views
Form
This is a migrated thread and some comments may be shown as answers.
Michael
Top achievements
Rank 1
Veteran
Michael asked on 15 May 2020, 03:52 PM
Can you use a textarea element as items.editor or make a TextBox multi-line

2 Answers, 1 is accepted

Sort by
0
Accepted
Dimitar
Telerik team
answered on 18 May 2020, 06:09 AM

Hello Michael,

Currently, rendering a textarea can be achieved through a custom editor function as follows:

editor: function(container, options) {
  $("<textarea class='k-textarea' required name='" + options.field +  "' data-bind='value: " +  options.field + "'></textarea>")
    .appendTo(container);
},

Here is a Dojo example that demonstrates the above. Important to outline is that when custom editors are rendered, the validation attributes need to be manually added to the input element in order for the validation functionality to work as expected.

In case you have any additional questions, please let me know.

Regards,
Dimitar
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
Michael
Top achievements
Rank 1
Veteran
answered on 18 May 2020, 09:17 AM
Thanks Dimitar, great help
Tags
Form
Asked by
Michael
Top achievements
Rank 1
Veteran
Answers by
Dimitar
Telerik team
Michael
Top achievements
Rank 1
Veteran
Share this question
or