[REBOL] Rebol view fields are caching entries - HELP
From: yvan_iigs:gmx at: 12-Nov-2006 16:45
I think I'm turning in circles.
I want to open a layout with a field where I can enter a filename and a
button 'Edit' to open the file with the filename I entered and allowing me
to edit it.
The editing stuff works more or less, but I have a very strange problem.
To explain it I created to very crude functions with just enough code to
show you the problem.
a layout with a field where I can enter the filename. A default value of
none is used.
A button 'EDIT' which by pressing it would call a function 'edit-file' with
the filename I entered or doing nothing if the default value of none is
still in it.
A button 'CANCEL' which just quits the function
Would do the editing stuff, but as this is not the problem I just entered
Okay, what is the problem.
-Start "select-file" for the first time
-> a view opens with a filename in the field of "none" as expected.
-Now enter dada as filename and press EDIT
-> works as expected
-Now, start "select-file" a second time
-> a view opens with a filename in the field of 'dada' instead of 'none'
,and this is very disturbing, unexpected stuff.
I tried many things, clearing strings, enabling trace, jumping out of the
window, but I am not able to find the reason of this problem.
what I want is that every time I start this function the default value of
'none appears in the field.
Who can help me please.
REBOL [title: "Creates File"]
["enter name manually and then edit"]
filename: field "none"
if/else NOT (filename/text = "none")
text "No filename selected"
button "OK" [unview]
button "CANCEL" [unview]
print "Will do some editing stuff"
Mit freundlichen Gr=FCssen