Hobbs
10-23-2009, 08:52 PM
I'm working on a richtextbox and i have 2 question
how can i tell if both shift and enter are pressed during a keydown method call?
So if a user hits enter do one thing, and the if they hold shift and hit enter do another. I would prefer to do this all in .net
and then ..
if i am using a case of expression, how can i "fall through" effect like you can get in c++
here's the function
on EditBox keyDown arg do
(
pressed = arg.keycode
case pressed of
(
(pressed.Enter ):
(pressed.Return):
(
EditBox.SelectedText = "\n"
)
(pressed.Tab):
(
EditBox.SelectedText = "\t";
)
)
)
I'd like the pressed.Enter and pressed.Return to have the same clause with out duplicating it.
Thanks
how can i tell if both shift and enter are pressed during a keydown method call?
So if a user hits enter do one thing, and the if they hold shift and hit enter do another. I would prefer to do this all in .net
and then ..
if i am using a case of expression, how can i "fall through" effect like you can get in c++
here's the function
on EditBox keyDown arg do
(
pressed = arg.keycode
case pressed of
(
(pressed.Enter ):
(pressed.Return):
(
EditBox.SelectedText = "\n"
)
(pressed.Tab):
(
EditBox.SelectedText = "\t";
)
)
)
I'd like the pressed.Enter and pressed.Return to have the same clause with out duplicating it.
Thanks
