Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: Injecting data into VID?

From: joel:neely:fedex at: 27-Apr-2001 9:21

("Hate to keep replying to my own questions!" he grumbled to himself...) I suppose another approach is to build the user interface spec explicitly, prior to invoking 'layout 8<-------------------- test1: make object! [ firstNames: ["John" "Jane" "Bob"] lastNames: ["Smith" "Doe" "Doaks"] uiSpec: [ across vh2 "Names:" return firstName: choice _FIRSTNAMES [sayName] lastName: choice _LASTNAMES [sayName] return fullName: info " " 200 return button "Close" [unview] ] replace/case uiSpec '_FIRSTNAMES firstNames replace/case uiSpec '_LASTNAMES lastNames ui: layout uiSpec sayName: function [] [theName] [ fullName/text: theName: join firstName/text [" " lastName/text] print mold theName show fullName ] run: function [][][ sayName view center-face ui ] ] test1/run 8<-------------------- Any suggestions for a tidier approach? -jn-