Hello,

Firstly, apologies about posting a similar problem because there have been different answers on what language and approach to take. This time, I'll try to describe the problem clearer.

In short, I have to display a rightclick menu only when the user rightclicks on a list item in a listbox. If the mouse is not at a list item, the menu will not appear when the user right clicks the mouse.

The listbox is an asp.net control, not a vb forms one. It is part of a custom control which consists of the asp.net listbox, a context menu and a label. The context menu is itself a custom control developed using c#, not one which is created by javascript. However, there is a javascript file which is included in the context menu code which is responsible for displaying the menu at where the user right clicks.

Hence, my custom control consists of 2 asp.net controls and another custom contro(a context menu having c# and javascript coding).

Are there any advice on how to let the asp.net listbox and javascript work together to display the menu only at the list items?

I used the context menu control (code included) from this website:
http://msdn.microsoft.com/msdnmag/is...e/default.aspx

Please advice