tags:

views:

86

answers:

0

I need to be able to pop-up a TForm when I right click on a TPaintBox (the content of the form will be dependent upon where I click). If the user clicks anywhere else I'd like the original form to be destroyed (or at least disappear). If the new click happens to be another right-click on the TPaintBox, a new TForm must appear. Basically, it's a right-click properties query type action i.e. right-click to get the properties of the area of the TPaintBox.

This seems to be more difficult than I imagined. I first tried to destroy the pop-up form when the pop was deactivated using the OnDeactivate event. This resulted in the popup not being shown.

Any ideas?

All help appreciated!

Cheers,

Steve Maughan http://www.cozmix.com