Hi Fran�ois,
I'm not quite sure I understand what you're trying to do, could you
provide a more complete example of your code?
Anyhow, have a look at this:
>> help write
Writes to a file, url, or port-spec (block or object).
Arguments:
destination -- (file url object block)
value --
Refinements:
/binary -- Preserves contents exactly.
/string -- Translates all line terminators.
...
Here's a little script, is this what you want?:
<script>
REBOL []
details!: make object! [
description: none
]
db: reduce [
79 make details! [description: "no. 79"]
80 make details! [description: "no. 80"]
81 make details! [description: "no. 81"]
]
print "Initial state:"
print mold db
foreach [record details] db [
if record = 80 [
details/description: "hello"
]
]
print "Modified state:"
print mold db
</script>
This is the output:
Initial state:
[
79
make object! [
description: "no. 79"
]
80
make object! [
description: "no. 80"
]
81
make object! [
description: "no. 81"
]]
Modified state:
[
79
make object! [
description: "no. 79"
]
80
make object! [
description: "hello"
]
81
make object! [
description: "no. 81"
]]
Best regards
Thomas Jensen
On 17-Nov-99, [EMAIL PROTECTED] wrote:
> Hi all...
>
> Can I append text to a block? I'm issuing the following command which seems
> rather simple...
>
> foreach [record details] db [
> [ if record = 80 [
> write details/description "hello"]
> ]
>
> with the following results....
>
> ** Access Error: Invalid port spec: testing the worf.
> ** Where: write details/description "hello"
>
> :(
>
> Any ideas
>