What does this syntax mean....
Forum rules
This forum is for discussing APL-related issues. If you think that the subject is off-topic, then the Chat forum is probably a better place for your thoughts !
This forum is for discussing APL-related issues. If you think that the subject is off-topic, then the Chat forum is probably a better place for your thoughts !
3 posts
• Page 1 of 1
What does this syntax mean....
I do not know how to read the following line of code that appear in some MiServer example code:
(frm←Add Form).id←'myform'
When I try executing it I get the error
3:SYNTAX ERROR: Invalid modified assignment, or an attempt was made to change nameclass on assignment
Direction[6] (frm←Add Form).id←'myform'
"CurObj" claims
Form
is
#.HTML.Input.Form (Operator)
However I think Form is supposed to be a Class.
(frm←Add Form).id←'myform'
When I try executing it I get the error
3:SYNTAX ERROR: Invalid modified assignment, or an attempt was made to change nameclass on assignment
Direction[6] (frm←Add Form).id←'myform'
"CurObj" claims
Form
is
#.HTML.Input.Form (Operator)
However I think Form is supposed to be a Class.
Ray Cannon
Please excuse any smelling pisstakes.
Please excuse any smelling pisstakes.
-
ray - Posts: 221
- Joined: Wed Feb 24, 2010 12:24 am
- Location: Blackwater, Camberley. UK
Re: What does this syntax mean....
Hi Ray,
I'll use an example outside of MiServer:
In your tests, is frm already defined?
Regards,
Vince
I'll use an example outside of MiServer:
'ns1' ⎕ns ''
'f' ⎕wc 'form'
⎕cr 'Add'
r←Add W
r←ns1
(frm←Add f).id←'myform'
frm
#.ns1
frm.id
myform
In your tests, is frm already defined?
Regards,
Vince
- Vince|Dyalog
- Posts: 413
- Joined: Wed Oct 01, 2008 9:39 am
Re: What does this syntax mean....
Thanks Vince. That make sense as far as it goes.
As to my error
First my item "frm" is not already defined.
Within your example, "f" is a name class 9 object.
While my "Form" is already defined by MiServer
(within the scope of the Render method) as an operator
⎕CR'Form'
r←{atts}(method Form)innerhtml
:If 9=⎕NC'atts' ⋄ atts←'action="',atts.Page,'"' ⍝ MildPage calling
:ElseIf 0=⎕NC'atts' ⋄ atts←'' ⋄ :EndIf
atts,←' method="',method,'"'
atts,←('post'≡#.Strings.lc method)/' enctype="multipart/form-data"'
r←('form ',atts)Enclose innerhtml
but I think "Form" should actually be a reference to the class #._HTML.Form
I think my class is not inheriting correctly from the _HTML class.
Thanks
As to my error
First my item "frm" is not already defined.
Within your example, "f" is a name class 9 object.
While my "Form" is already defined by MiServer
(within the scope of the Render method) as an operator
⎕CR'Form'
r←{atts}(method Form)innerhtml
:If 9=⎕NC'atts' ⋄ atts←'action="',atts.Page,'"' ⍝ MildPage calling
:ElseIf 0=⎕NC'atts' ⋄ atts←'' ⋄ :EndIf
atts,←' method="',method,'"'
atts,←('post'≡#.Strings.lc method)/' enctype="multipart/form-data"'
r←('form ',atts)Enclose innerhtml
but I think "Form" should actually be a reference to the class #._HTML.Form
I think my class is not inheriting correctly from the _HTML class.
Thanks
Ray Cannon
Please excuse any smelling pisstakes.
Please excuse any smelling pisstakes.
-
ray - Posts: 221
- Joined: Wed Feb 24, 2010 12:24 am
- Location: Blackwater, Camberley. UK
3 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 1 guest
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group