How can I validate a textbox/data source against a secondary data.

D

David Kassa

Hi all,

I want to have a textbox/Main data source validate against a secondary data
source. I can do this by looking up values in a list box, but I don't like
that the box stops sorting after the first typed character. It forces the
operator to have to use a mouse or arrow keys. Instead, I'd like to have
free text, but check the value after the update.

I thought it would be as simple as in Validation saying "Field not equal to
@SecondarySource", but this statement never evaluates as true.

I am using repeating sections on the primary data source and only want to
use the secondary data source for validation. if additional information is
needed, please ask.

Thanks in advance for any help!

David Kassa
 
D

David Kassa

Hi Greg,

Thanks for the reply! That's actually what I've tried doing, but like I
said in my 1st post the field never evaluates as true when I try this. Could
it be because I don't use the secondary source on my form - just for
validation? Are there additional steps needed to compare the values or
initialize the secondary source? Perhaps a trim function? (I'll try that one
next :) )

David Kassa
 
S

Steve van Dongen [MSFT]

Hi Greg,

Thanks for the reply! That's actually what I've tried doing, but like I
said in my 1st post the field never evaluates as true when I try this. Could
it be because I don't use the secondary source on my form - just for
validation? Are there additional steps needed to compare the values or
initialize the secondary source? Perhaps a trim function? (I'll try that one
next :) )

David Kassa

Greg Collins said:
When writing your validation condition, the third drop-down list has Select Field Or Group. If you choose this, you can locate the field or attribute in your secondary data source that you want to use for validation.

--
Greg Collins [InfoPath MVP]
Please visit: http://www.InfoPathDev.com



Hi all,

I want to have a textbox/Main data source validate against a secondary data
source. I can do this by looking up values in a list box, but I don't like
that the box stops sorting after the first typed character. It forces the
operator to have to use a mouse or arrow keys. Instead, I'd like to have
free text, but check the value after the update.

I thought it would be as simple as in Validation saying "Field not equal to
@SecondarySource", but this statement never evaluates as true.

I am using repeating sections on the primary data source and only want to
use the secondary data source for validation. if additional information is
needed, please ask.

Please post the relevant code.

Regards,
Steve
 
D

David Kassa

Hi Steve,

There really is no code associated with this problem. Should I be using
code to accomplish this?

Steve van Dongen said:
Hi Greg,

Thanks for the reply! That's actually what I've tried doing, but like I
said in my 1st post the field never evaluates as true when I try this. Could
it be because I don't use the secondary source on my form - just for
validation? Are there additional steps needed to compare the values or
initialize the secondary source? Perhaps a trim function? (I'll try that one
next :) )

David Kassa

Greg Collins said:
When writing your validation condition, the third drop-down list has Select Field Or Group. If you choose this, you can locate the field or attribute in your secondary data source that you want to use for validation.

--
Greg Collins [InfoPath MVP]
Please visit: http://www.InfoPathDev.com



Hi all,

I want to have a textbox/Main data source validate against a secondary data
source. I can do this by looking up values in a list box, but I don't like
that the box stops sorting after the first typed character. It forces the
operator to have to use a mouse or arrow keys. Instead, I'd like to have
free text, but check the value after the update.

I thought it would be as simple as in Validation saying "Field not equal to
@SecondarySource", but this statement never evaluates as true.

I am using repeating sections on the primary data source and only want to
use the secondary data source for validation. if additional information is
needed, please ask.

Please post the relevant code.

Regards,
Steve
 

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