
Signature
Clay Fox / Microsoft InfoPath MVP
www.InfoPathDev.com / The InfoPath Authority / Downloads, Samples, How-To,
Experts, Forum
Hi Clay,
I already had such an idea. If I had only one or two such fields, that would
be no problem....but the form I work on has more than 40 fields with cross
validation rules...
Another situation that I met is the following:
I have two fields (txtField1 and txtField2) and I have put a validation rule
so that when the user put something in one of the two fields, he must put
something in the other field. To do that, I defined a "validation rule" on
each field with such condition:
- txtField1 is empty AND txtField2 is not empty on txtField1
- txtField2 is empty AND txtField1 is not empty on txtField2
but now, if user put a space character in txtField1, the txtField2 is
marqued as an error (with a red star) and yet txtField1 is empty (for the
user point of view).
I think there is a bug of incoherence between the data stored in XML and
data displayed in the form. If a field is displayed "blank", the value of the
field in XML should be considered as empty...here is not the case.
Regards.
Eric.

Signature
Cordialement.
Eric.
> You could add a conditional rule or to that after change the field was spaces
> that it would set it to empty string or a default or something. You could
[quoted text clipped - 23 lines]
> >
> > Eric.
Clay Fox - 26 Mar 2008 16:57 GMT
Hey Eric.
Yah validation is a pain.
Sounds like these users like their space bar.
Some times you can create a hash type field.
Say for your 40 dates, have one field that concatenates them all into one
string.
Then use a contains to check for any spaces. If the field is blank it will
be skipped but if it has space that would get concatenated in and you could
detect it. Unfortunately you cannot say which field but you can block the
user until they get their dates cleaned up.
This probably would not work on your text fields, for those I would check
them for a space and then reset them to empty.

Signature
Clay Fox / Microsoft InfoPath MVP
www.InfoPathDev.com / The InfoPath Authority / Downloads, Samples, How-To,
Experts, Forum
> Hi Clay,
>
[quoted text clipped - 48 lines]
> > >
> > > Eric.