I've been exploring the amazing Rebol programming tool. I've run into a problem of trying to append text from a text field into the data of a text-list. My code below adds text to the text-list but changes all previous text to the current one multiplied by how many data entries were already in the text list.
How can I correct this?
REBOL [
Title: "test4"
Version: 1.3.3
Author: "me"
Purpose: {create a list of countries}
]
populate: does[
country: countryField/text
append txtList/data country
show lay
]
lay: layout [
across
text "Enter name of country" black bold
countryField: field
return
across
txtList: text-list
panel [
button "Add" [populate]
button "Delete" [remove back tail txtList/data show lay]
button "Clear" [clear txtList/data show lay]
]
]
view lay