[REBOL] Re: What is the difference...
From: greggirwin::mindspring::com at: 11-Dec-2002 10:31
Hi Philippe,
PO> Could someone help me about the difference between :
PO> a: [field5/text: "hello" show field5]
PO> do a ; the change is done
PO> b: compose/deep [(to-set-word join "field" [5 "/text"]) "hello" show
PO> (to-word join "field" "5")]
PO> do b ; nothing is done in /View 1.2.03
PO> The a and b block are the same. How Can I make the b-block effective
They may look the same to you, but they aren't. :)
view layout [
field5: field
button "A" [
a: [field5/text: "helloA" show field5]
do a ; the change is done
]
button "B" [
b: compose/deep [
(to-set-word join "field" [5 "/text"]) "helloB"
; This should work for you
;set in get (to lit-word! join "field" 5) 'text "helloB"
show (to-word join "field" "5")
]
do b ; nothing is done in /View 1.2.03
]
button "Same?" [
print same? a b
print equal? length? a length? b
repeat i length? a [
print [type? a/:i tab type? b/:i]
]
]
]
HTH!
-- Gregg