home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Utilities / Programming / Dialog Director 0.6 / Examples / Menu+.as < prev    next >
Encoding:
Text File  |  1997-04-08  |  847 b   |  18 lines  |  [TEXT/ToyS]

  1. on run
  2.     set d to current date
  3.     set dd to d's date string
  4.     DoMenu(["One", "Two", "Three", "Four", 5, 6, 7, 8, 9, 10, 11, 12, 13 ¬
  5.         , d's time string, word 1 of dd, third word of dd, last word of dd])
  6. end run
  7.  
  8. on DoMenu(theItems)
  9.     set dItems to [¬
  10.         {class:push button, bounds:{190, 265, 250, 285}, name:"OK"}, ¬
  11.         {class:push button, bounds:{110, 265, 170, 285}, name:"Cancel"}, ¬
  12.         {class:group box, bounds:{10, 15, 250, 220}, name:" Choose an option: ", style:secondary group}, ¬
  13.         {class:radio group, bounds:{20, 30, 120, 46}, button offset:[105, 20], max down:9, contents:theItems}, ¬
  14.         {class:text field, name bounds:{10, 230, 40, 246}, name:"Edit", bounds:¬
  15.             {50, 230, 250, 246}, value:"The quick brown fox jumps over the lazy dog."} ¬
  16.             ]
  17.     get dd auto dialog {size:{260, 295}, contents:dItems, timeout after:60} with greyscale
  18. end DoMenu