[REBOL Path failure?
[1/4] from: sharriff:aina:med-iq at: 27-Sep-2000 10:50
Hi guys!
can anyone tell me why this path fails?
>> load %test.r
== [
users: [admin: [
name "name-admin"
email "name-admin"
]
]
]
>> print users/admin/name
** Script Error: users has no value.
** Where: print users/admin/name
>>
Sharriff Aina
med.iq information & quality in healthcare AG
[2/4] from: al:bri:xtra at: 27-Sep-2000 22:10
Sharrif wrote:
> can anyone tell me why this path fails?
> >> load %test.r
<<quoted lines omitted: 8>>
> ** Script Error: users has no value.
> ** Where: print users/admin/name
Try:
users: load %test.r
and make sure that your block looks like this before set-ing 'users:
[
admin [
name "Another User"
email [A--User--med-iq--de]
]
]
Note that the extra level of nesting has been eliminated and the colon
:
after "admin" has been deleted.
I hope that helps!
Andrew Martin
ICQ: 26227169
http://members.nbci.com/AndrewMartin/
http://members.xoom.com/AndrewMartin/
[3/4] from: al::bri::xtra::co::nz at: 27-Sep-2000 22:21
Here's a working example:
>> users: [
[ admin [
[ name "Another User"
[ email [A--User--med-iq--de]
[ ]
[ ]
== [
admin [
name "Another User"
email [A--User--med-iq--de]
]
]
>> users/admin/name
== "Another User"
>> users/admin/email
== [A--User--med-iq--de]
>> save %test.txt users
>> u: load %test.txt
== [
admin [
name "Another User"
email [A--User--med-iq--de]
]
]
>> u
== [
admin [
name "Another User"
email [A--User--med-iq--de]
]
]
>> u/admin/name
== "Another User"
I hope that helps!
Andrew Martin
ICQ: 26227169
http://members.nbci.com/AndrewMartin/
http://members.xoom.com/AndrewMartin/
[4/4] from: sharriff:aina:med-iq at: 27-Sep-2000 11:45
I just tried it out. I works fine thanks!
Sharriff Aina
med.iq information & quality in healthcare AG
Notes
- Quoted lines have been omitted from some messages.
View the message alone to see the lines that have been omitted