Hello all,

I am again not going to post any code here because I know my issue is with my code that I have created, thus everything probably will have to be re-written. Here is my issue:

I have a form with a listview control, some buttons and a menu bar. When the form loads, the user can select one of the menu bar options and open one of two types of word lists. After the words are displayed in the listview, some of the menu options are changed (either disabled or enabled) and the same happens to the buttons. This is all based upon what type of word list is opened (loaded). I might want to tell you that the shortest of the lists may contain a maximum of 6500 words. Currently I do not have ANY issue with loading the words very fast. No, I am not loading these words in virtual mode. I don't understand this.

Now, when the user selects any single word - the buttons are to change state (disable / enable). The code for this function is not directly written into the listview event - it is called. What happens is that IF a user selects 1 word, the code that decides what buttons need to change runs once - great. Now if the user selects 1 word, then holds down the shift button and selects a word (ie: 155 lines down) then this code runs 155 times!

My goal is to define what buttons need to be disabled or enabled based upon how many words are selected and the type of word list opened. I don't need this code to run each and every time a word is selected.

I am also attempting to show the user how many words (ListView items) are selected in a label on this same form. This is also updated with each item selected. I would only like to show a total selected AFTER the last item is selected.

Does anyone have any idea how I can improve the function of this "list editor"?