Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / May 2005

Tip: Looking for answers? Try searching our database.

Bug in Text Box Data Validation using script based rule

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
RobinW - 26 May 2005 17:26 GMT
Hi

I've double check this and it seems to be broken.

Used the http://www.infopathdev.com/nuggets/default.aspx nuggest change
to allow xdExtension scripted code in rules.

My rule (a simple function which is working fine and allready used to
enable and disable buttons).

But if i try and add it to a text box data validation to show * when
the data is invalid and my function is true
i.e in Data validation ...

text box is empty AND expression xdExtension:MyScriptFunction() == True

should cause the * to appear when this is evaluated except it doesnt

changing the validation to simply xdExtension:MyScriptFunction() ==
True

Still doesnt work untill something is typed in the text box then
deleted and the cursor focus moved to another fiell THEN the * finally
appears unlike if it was just 'text box is empty' then the * is there
from the start

Hope this makes sense.

Robin
MatsonPP - 26 May 2005 18:13 GMT
This is because events don't fire until focus is moved to another spot.
RobinW - 27 May 2005 08:03 GMT
Nope its a bug - if i have two fields one with the 'text box is empty'
* condition and the other with 'text box is empty AND expression
xdExtension:MyScriptFunction() == True'

and both fields are empty and the condition evaluates correctly etc etc

One has a * one doesnt

thats a bug to me

Rob
MatsonPP - 31 May 2005 15:22 GMT
It probably doesn't understand your function. You as a human undestand
it, but you can't expect InfoPath to go through and evaluate your
function with test data to see whether it says this textbox must be
required. For all InfoPath knows "xdExtension:MyScriptFunction() ==
True" could mean that your function evaluates to true when the textbox
is blank.

So there you have it, not a bug :)

See ya,
Matt

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.