[rdnzl-devel] Keys comparision

Hello, I will like make a "between" comparison of Keys enumerator. The below code works fine, but I will like know if [%KeyCode e] is between [$Keys.D0] and [$Keys.D9] (defun learning () (let ((form (new "Form"))) [+KeyDown form (new "KeyEventHandler" #'(lambda (o e) (declare (ignore o)) (cond ([Equals [%KeyCode e] [$Keys.D0]] (message-box "Zero")))))] form)) Regards Francisco Rivera jfrivera56@hotmail.com

On Sun, 2 Jan 2005 16:10:27 -0600, "Francisco Rivera" <jfrivera56@hotmail.com> wrote:
I will like make a "between" comparison of Keys enumerator.
The below code works fine, but I will like know if [%KeyCode e] is between [$Keys.D0] and [$Keys.D9]
(defun learning () (let ((form (new "Form"))) [+KeyDown form (new "KeyEventHandler" #'(lambda (o e) (declare (ignore o)) (cond ([Equals [%KeyCode e] [$Keys.D0]] (message-box "Zero")))))] form))
How about ENUM-TO-INTEGER? Cheers, Edi.
participants (2)
-
Edi Weitz
-
Francisco Rivera