XML Schema / InfoPath Data Source questions

S

Shan McArthur

Hello,

I am importing an XSD file for the data source of an infopath project. The
data model doesn't seem to import the 'cannot be blank' attribute quite
right. Here are a couple of questions I have:

1. I have some XML attributes that are marked as use="optional" in the XSD
schema. In Infopath, these are imported as "cannot be blank". Attributes
that are strings are imported as I expect, but the attributes that are typed
to dates and integers do not behave as expected.

2. I have a similar problem with elements as with attributes, only when I
have minOccurs="1", Infopath does not mark the element as "cannot be blank".

I need to fix these issues because I need to show and hide form elements
that are bound to these data elements. Since I cannot get the data elements
to properly respect if they are needed or not, I cannot successfully show or
hide the form fields.

I really have not found a good reference on the data model that would help
me with these issues. Any help would be appreciated.

Thanks,
Shan McArthur
 
V

virgul

Hi,

The probleme is that for infopath a value cannot be blank if it's a
no-string type!

So a work around is to add nillable="true" to your element !


++

Thierry
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top