(in-package :custom) (use-package :oli) ;(defvar *tp-leiter-tool* nil) (sd-defdialog 'tp_beispiel_dialog :dialog-title "Siehe Skizze" :dialog-type :terminate :taskBarPage nil :embedded-ui nil ;; default = t :toolbox-button t :after-initialization '(progn (let (var-werte) (setq var-werte (sd-get-persistent-data "ALL" "UICT-TPLEITER1" :subkey :TP-Leiter)) (when (listp var-werte) (sd-set-variable-status 'tp_hal_h1 :value (getf var-werte :wert1)) (sd-set-variable-status 'tp_hal_h2 :value (getf var-werte :wert2)) ) ) );;ende progn :variables '( (test_bol :title "Skizze" :push-action (tp_leiter_skizze) :toggle-type :wide-toggle ) (tp_hal_h1 :initial-value 500 :initial-enable t :value-type :length :title "Höhe" :prompt-text "Höhe vom 1. Halter eingeben" :after-input (progn );;ende progn ) (tp_hal_h2 :initial-value 200 :initial-enable t :value-type :length :title "Tiefe" :prompt-text "Höhe vom 1. Halter eingeben" :after-input (progn );;ende progn ) );;ende Variablen :ok-action '(progn (let (var-werte) (setq var-werte (list :wert1 tp_hal_h1 :wert2 tp_hal_h2 ) ) (sd-set-persistent-data "ALL" "UICT-TPLEITER1" var-werte :subkey :TP-Leiter :store-flag t) ) );;ende progn :cancel-action '(progn (sd-destroy-dialog-shell "UICT-TPLEITER1") );;ende progn :local-functions '( ;;============================================================================================================= (tp_leiter_skizze () ; (sd-create-image "tp_l1_skizze" :filename "\\\\temp\\Logo.bmp") (sd-create-dialog-shell "UICT-TPLEITER1" :title "Leiter geschweißt" :bottomLine :none ) (sd-append-area "UICT-TPLEITER1-1-AA" "UICT-TPLEITER1-AA" :frame nil :title "" :margin 7 :titleForeground "#ffff00" :background :option ) (sd-append-grid-area "UICT-TPLEITER1-11-GA" "UICT-TPLEITER1-1-AA" :frame t :title "Skizze" :width 500 :height 500 :cellSize 20,20 ) ; (sd-create-label-control "UICT-TPLEITER1-111-LB" "UICT-TPLEITER1-11-GA" ; :image "tp_l1_skizze" ; :x 6 ; :y 0 ; :width 10 ; :height 10 ; ) (sd-create-text-control "UICT-TPLEITER1-1111-TX" "UICT-TPLEITER1-11-GA" :x 0 :y 3 :width 4 :height 1 :editable t :showModified nil :showFocus t :enterAction '() ) (sd-create-text-control "UICT-TPLEITER1-11111-TX" "UICT-TPLEITER1-11-GA" :x 0 :y 6 :width 4 :height 1 :editable t :showModified nil :showFocus t :enterAction '() ) (sd-create-pushbutton-control "UICT-TPLEITER1-ok-PB" "UICT-TPLEITER1-11-GA" :x 0 :y 0 :width 4 :height 2 :title "OK" :pushAction '(when (and (numberp (sd-read-from-string(sd-get-text-control-value "UICT-TPLEITER1-1111-TX" :trimString t))) (numberp (sd-read-from-string(sd-get-text-control-value "UICT-TPLEITER1-11111-TX" :trimString t))) ) (let (var-werte) (setq var-werte (list :wert1 (sd-read-from-string(sd-get-text-control-value "UICT-TPLEITER1-1111-TX" :trimString t)) :wert2 (sd-read-from-string(sd-get-text-control-value "UICT-TPLEITER1-11111-TX" :trimString t)) ) ) (sd-set-persistent-data "ALL" "UICT-TPLEITER1" var-werte :subkey :TP-Leiter :store-flag t) ) (sd-destroy-dialog-shell "UICT-TPLEITER1") (sd-call-dialog 'tp_beispiel_dialog) );;end when ) (sd-show-dialog-shell "UICT-TPLEITER1" :position '(:application :upperleft 250 0) ) );;ende tp_leiter_skizze );;ende local functions );;ende dialog