Performance of IntelliPrompt.MemberList.Show

SyntaxEditor for Windows Forms Forum

Posted 13 years ago by Dong JIA
Version: 3.1.0213
Avatar
Hi all,
I want to support COM constants in MemberList for office, the performance is very poor.
For Example, Excel + PowerPoint + Word have about 5000 contants. When I show them in MemberList, it takes several seconds. It is unacceptable for a editor. :(
Do I miss something important?
Any advices is welcome.
Thanks in advance.
DeepNight

Comments (3)

Posted 13 years ago by Boyd - Automated Software Testing Consultant / Developer, Patterson Consulting, LLC
Avatar
How are you adding to them to the MemberList? If you add them one-by-one, that would result in poor performance. If you add all the items at the same time from an array, that works much better. If you're not using that approach, give it a shot and see how it works out.

Another option would be to cache all your constants. You can generate an array holding all the MemberList items for the constants in Excel, PowerPoint, and Word. When you need to show them in a member list, just add the array to the list.
Posted 13 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Yes, Boyd said it correctly. Since adding member list items is adding them directly to a ListBox, each time you add an item you are forcing a layout. Therefore, it's best to build up an array of items on your own, then add them all at once with AddRange to achieve maximum performance.

Also, sorting might be causing some slowdown with that many items but it is necessary for the keyboard to pick up the proper items as you type. Alternatively you could probably pre-sort the items and turn off sorting on the member list itself.


Actipro Software Support

Posted 13 years ago by Dong JIA
Avatar
Thanks for your response!
You are right. I has test my code: it spends 0.3 second to show and spends 4 seconds to insert item.
I will improve the method to insert item.
Really really thanks. :)
The latest build of this product (v2018.1 build 0341) was released 9 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.