Without looking at the code, did you put breakpoints in your code at the first line of the command button's click event and the image's click event?

If you break into those and step through, you can try to see where it "freezes" and try to figure out why.



Looking in the code (because I had more time than I thought), I see why it stops adding the places. Your variable CheckLine is used to see if it's already in the list. Now, in your case, it's a public variable, which means it keeps whatever value you set it to even when you go into another function.

In your case, since you never reset it when clicking on any of the image, it never resets to 0, so even if the area you're clicking on isn't found, CheckLine keeps it's non-zero value and your program believes that the area they clicked on is in the list, even though it's not.


I didn't look into your Clear Selected event, but just looking at the code, I don't see where it could fail like that.