Shift or Control + MouseDown in Web

How can I figure out if the shift key is down (or the control key is down) when I get a MouseDown event from a WebControl?

I want to enable the user to either select 1 item (no key pressed simultaneously) or multiple items (MouseDown while holding down the control-key). That is what I am trying to accomplish.

I want to do the same thing. Any ideas on this one?

That takes care of Ctrl-Mousedown or right click.

I must be missing something; I only see:

NoMouseButton 0
LeftMouseButton 1
OtherMouseButton 3
RightMouseButton 2

How would I differentiate between Ctrl-Mousedown or Mousedown. Or will Ctrl-Mousedown return 3 (OtherMouseButton)?

And is there a way to detect the shift pressed? Long selections would be unhandy using only ctrl…

Mark & Robert, If you are referring to a listbox, “Multiline” option for the control will provide you with what you are asking.

You cannot detect shift by itself from a web app AFAIK.

In Mac, Ctrl-MouseDown means right click. Ctrl-MouseDown will return 2.

On Windows, Ctrl-Click does nothing special.

Thanks Bob - I think I submitted this question originally 3 years ago when I was creating my own web listbox based on container controls to enable images and other enhanced functions. I have successfully used WebListbox (and I think it allows multiline selection [or at least support] by default).