This preview shows page 1. Sign up to view the full content.
Unformatted text preview: (define x (make-object text-field% "" p void ""))) x)) (define Input1 (make-named-text "Input 1")) (define Input2 (make-named-text "Input 2")) (define calc-button (make-object button% button-descr main-panel (lambda _ (local [(define result (callback (string->number (send Input1 get-value)) (string->number (send Input2 get-value))))] (send output set-value (format "~a" result)))))) (define output (make-named-text "Output"))] (send frame show #t))) )...
View Full Document
This note was uploaded on 02/06/2008 for the course CS 1102 taught by Professor Fisler during the Fall '07 term at WPI.
- Fall '07