Version 6 of Invoice-Demo

Updated 2015-05-19 13:46:33 by MiHa

if 0 {


Introduction

MiHa 2015-05-13: This is a demo for a tcl/tk-program with all the essential GUI-elements.
It is simple invoice-program with menu, entry-form and output (planned: one printed page).

With ideas and code from the following pages:

}


Program 1

 # InvoiceDemo01.tcl - Mike Hase - 2015-05-17
 # http://wiki.tcl.tk/29284

 set FieldNames {Date Title Name Street City Phone  art1Nr art1name art1price} 
 set f 0

 frame .f1
 foreach field $FieldNames {
        incr f
       #set data($f) $f
        set lb [label .f1.lb$field -text $field]
        set en [entry .f1.en$field -justify right -textvar data($f) ] 
        grid $lb $en -padx 4 -pady 2
        grid $lb -sticky e
        grid $en -sticky ew
    }

 frame .f2
 button .f2.b1 -text New     -command { bell }
 button .f2.b2 -text Test1   -command { bell }
 button .f2.b3 -text Test2   -command { bell }
 button .f2.b4 -text Show    -command { bell }
 button .f2.b5 -text Print   -command { bell }
 button .f2.b6 -text Exit    -command { exit }

 grid .f2.b1  .f2.b2  .f2.b3  .f2.b4  .f2.b5  .f2.b6
 pack .f1 .f2 -side top

 set data(1) "2015-05-13"

 ### EOF ###

Output

Invoice-Demo:
...

Remarks

This is not-yet the Alpha-version, ...


See also: