Hello,

I like to thank the person who told me to read the sources and to use
do-events. Unfortunately I don't remember who it was.

Now the function works but it doest something that it shouldn,t. Here aga=
in
the basic idea.


What it should do is the following:

1. I have a block a with a string in it
2. Edit-ActorRole should open a form with the value of the string in bloc=
k a
and let the user edit it if he wants.
3. The edited string should be returned to block b, letting block a =

untouched

Part 3 does not work


for example:

a: ["dada"]
b: Edit-ActorRole a

but the value of a is also changed and this should not be,



>> b
=3D=3D [["Yvan"]]     ; this is good, the value Ichanged it in the form


>> a
=3D=3D ["Yvan"]       ; this should not be    =

>>

 here the code.


REBOL []


Edit-ActorRole: func [ actor-block [block!]
                       /local l-act-role-block =

                        l-actor-block
                        ] =

[
 l-act-role-block: copy  []
; I use the copy function to be sure not to use a pointer.
 l-actor-block: copy actor-block
 =


 if (l-actor-block/1 =3D none) [append l-actor-block ""]
  Formular: view/new layout
  [
   text "Actor 1:" Fact1: field  l-actor-block/1
   button #"^M""OK" =

   [
    l-actor-block: copy  []
    if not (Fact1/text =3D "") [append l-actor-block Fact1/text] =

    append/only l-act-role-block l-actor-block
    unview
   ]
  ]
 do-events;
 return l-act-role-block
]  =







Mit freundlichen Gr=FCssen
Yvan =

-- 
To unsubscribe from the list, just send an email to 
lists at rebol.com with unsubscribe as the subject.

Reply via email to