Re: [Xsltforms-support] Error handling and display
Brought to you by:
alain-couthures
From: Robert K. <ro...@er...> - 2019-05-01 15:41:17
|
Additional point: My test relies on a BaseX http server, as you can see from the xsltforms url (port 8984). This should not make a difference, but well a variation with the tests you made. Regards, Robert. On Wed, May 1, 2019 at 2:58 PM Robert Kirkpatrick <ro...@er...> wrote: > Very strange. > I'm using Chrome Version 73.0.3683.103 > > On Wed, May 1, 2019 at 12:58 PM Steven Pemberton <ste...@cw...> > wrote: > >> On Tue, 30 Apr 2019 19:29:39 +0200, Robert Kirkpatrick <ro...@er...> >> wrote: >> >> Thank you Steven. >> >> Indeed type errors show up clearly. But in my example, the displayed >> values were not typed in via the form, but defined in the <instance/> as >> default values: ? for item, 0 for amount. >> And very weirdly, they are output *concatenated* in *both* form fields !! >> An X error flag indicates a problem, not surprising, but totally blind.. >> !? >> >> >> I ran your test in 4 different browsers, and didn't get this problem. >> >> Steven >> >> >> >> Robert. >> >> On Tue, Apr 30, 2019 at 2:14 PM Steven Pemberton <ste...@cw...> >> wrote: >> >>> On Tue, 30 Apr 2019 11:35:47 +0200, Robert Kirkpatrick < >>> ro...@er...> wrote: >>> >>> (Newcomer first post) >>> >>> Hello, >>> >>> Here is a basic Xform: >>> [image: image.png] >>> >>> When I hover over the error flags, I only get a little question mark. >>> What can I do to display the error associated with the event, which I >>> can't identify? >>> >>> As far as I recall, you only get the red X if the value doesn't match >>> the node's type or constraints. >>> >>> I don't understand why you are getting an X for Item, because that's a >>> string; amount is an integer, and ?0 is not a valid integer value, so >>> that's why you are getting it there. >>> >>> To get a message to show, you need to include an <alert/> element in the >>> input; for instance >>> >>> <xf:label>Amount:</xf:label><xf:alert>Must be an integer</xf:alert> >>> >>> >>> There must be some binding mistake in the form, here attached, but the >>> messages associated with xforms-binding-error are not displayed. >>> >>> The bindings are fine. If there were a binding error, the control would >>> not show up. >>> >>> Hope this helps somewhat. >>> >>> Steven >>> >>> >>> Thanks for any help, >>> Robert. >>> >>> >>> >>> >>> >> >> >> |