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

Performance really bad?

3 Answers 292 Views
TextBoxControl
This is a migrated thread and some comments may be shown as answers.
Troy
Top achievements
Rank 3
Bronze
Iron
Iron
Troy asked on 08 Sep 2020, 05:14 AM

I've pasted 26k of data into the textbox and things go really bad.  The max characters for this say it should handle 2,147,483,647, but there is no way I've experienced anything remotely close to that.

The problems:

  Scrolling is choppy and slow

  I can CTRL-A to highlight everything (which is fairly fast), then I right and get the context menu, but I can't ever select Copy.

  Any more data than the above 26k, the control is pretty much just locked up.

To Reproduce:

In order to make sure it wasn't my app causing the issue, I created a new app, dropped a radTextBoxControl onto it.  Resized it to 1218, 828 (randomly chosen), then ran the app.

I pasted the same 26k of data (XML content, but it doesn't seem to matter what it is), and the same issues I first described above happened.

3 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 10 Sep 2020, 12:33 PM

Hi, Troy,

I would like to clarify how RadTextBoxControl works: It parses the text and creates a Visual Elements for every word in the text which is a very time and memory consuming process. This control is more suitable for small amounts of text <2k.

Instead of using RadTextBoxControl you can use RadTextBox (which hosts internally a MS TextBox control) or you can RadSyntaxtEditor. As of R1 2020 Telerik UI for WinForms suite offers a RadSyntaxEditor control. RadSyntaxEditor is a useful text editor control which provides built-in syntax highlighting:

I hope this information helps.

Regards,
Peter
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

0
Troy
Top achievements
Rank 3
Bronze
Iron
Iron
answered on 10 Sep 2020, 10:16 PM

Thanks Mark for the answer, I've switched controls and things are working as expected.  You might want to limit the max size or at least put some sort of warning on it as when I see the default max size is 2gig of data, I expect the control to be able to handle it.

All good though and I appreciate the help!

0
Peter
Telerik team
answered on 15 Sep 2020, 05:32 AM

Hello, Troy,

Thank you for your suggestion. We can consider changing the documentation or/and we can add a warning in the control.

If you need any further assistance please don't hesitate to contact me. 

Regards,
Peter
Progress Telerik

Five days of Blazor, Angular, React, and Xamarin experts live-coding on twitch.tv/CodeItLive , special prizes and more, for FREE?! Register now for DevReach 2.0(20).

Tags
TextBoxControl
Asked by
Troy
Top achievements
Rank 3
Bronze
Iron
Iron
Answers by
Peter
Telerik team
Troy
Top achievements
Rank 3
Bronze
Iron
Iron
Share this question
or