Re: Instances, Models and <bind>

Robert

You cannot refer to an instance in A model in a bind in B model. The only
feature of XForms that allows you to combine instances from different models
in any way is select/select1 and itemset.

The argument goes that if you want to combine models, you should author
model fragments and pull them together into one model using XInclude.
 
All the best

Mark

-- 

The information in this email is sent in confidence for the addressee only
and may be legally privileged. Unauthorised recipients must preserve this
confidentiality and should please advise the sender immediately of the error
in transmission. If you are not the intended recipient, any disclosure,
copying, distribution or any action taken in reliance on its content is
prohibited and may be unlawful.

Origo Services Ltd accepts no responsibility for any loss or damage
resulting directly or indirectly from the use of this email or the contents.


> From: "Robert Bateman" <bobbateman@sequoiallc.com>
> Date: Fri, 2 Apr 2004 13:17:00 -0500
> To: <www-forms@w3.org>
> Subject: Instances, Models and <bind>
> Resent-From: www-forms@w3.org
> Resent-Date: Fri,  2 Apr 2004 13:18:08 -0500 (EST)
> 
> 
> In looking at a bunch of examples from around the web, I've noticed people
> seem to have implemented the 1 instance per model method in their forms.
> 
> Not being all that comfortable - yet - with Xforms, my "test" form has 3
> instances inside of one model.  Seeing how crowded this has made my form, I'm
> attempting to break things up a bit.  But I've run into a bit of a
> confusion...
> 
> I have 3 instances:  xmlData, scratchPad and guiData.  xmlData will,
> eventually, be sent off to the server for processing.  But some fields in
> xmlData require lists and other selectable data that is stored (and
> referenced) from the scratchPad instance.  And some fields, especially the
> ones that are "optional" are stored in the guiData instance with xmlData
> using <relevant> to control inclusion of the specific data.
> 
> Now to the "problem".  If I put the guiData instance into a seperate model I
> start to get syntax errors in my form.  So I have to assume my <input>,
> <output>, etc. items need to have @model specified.  So far so good.
> 
> But as I look at my <bind> definitions, I find many of the binds reference
> datum in other models.  Does it matter in Xforms if I have a <bind> in one
> model that references instance data in a different model?
> 
> Bob
> 
> 

Received on Wednesday, 7 April 2004 05:12:43 UTC