Ask a Question related to Adobe Acrobat SDK, Design and Development.
-
smde@adobeforums.com #1
Field level behavior using Javascript
I am using Live Cycle designer with an XFA form that is reading its data from an XML data file -
This is the best feature in all of Adobe land, etc ....
however....
in the real world - not all XML environments are the same or even sane.
I have a situation where the schema is only being loosely adhered to - mostly in newer instances of the data suppler - while older data retains some legacy processing : like
Not using a unique XML Element to define a separate data segment - but rather embedding important processing data at the value level .
So ,with all that being said, my question is this -
Is there a way to check the contents of a field - determine that I don't want to display ti- or that I do want to display it ???
I don't just want an error message stating that it isn't X, or Y or Z ... , etc.
For instance if I wanted to skip anything that had a null field for a particular field value - .
if (this.rawValue == ""} {"do something : like set to a value that will fail the validate script ... };
If I test it after the bind event - then follw that with a validation script ... etc ....
This is what I am hoping that I can do .
smde@adobeforums.com Guest
-
enable review via document level javascript
Dear all, My requirement is to programmatically enable shared for review functionality. I am half way through my requirement. I enabled the... -
add document level javascript from code
Is it possible to use code (preferably IAC) to add document level Javascript (functions or document open actions) to a pdf? The only idea I can... -
designtime javascript behavior ?
Hi all, How to access html object in designtime (vs.net use IE at designtime) and manipulate it ? I want to create a component that has a rich... -
copy and paste form RTF document into field in asp form cause it to bypass field length and javascript validation - how to overcome?
I have a web form with several fields. If I copy & paste from a RTF document into a field, the javascript validation and field length are bypassed... -
Memo field behavior
Hello, In one application I can hit ctrl enter and get a new paragraph and in the second application I cannot. Both are memo fields. The only... -
smde@adobeforums.com #2
Re: Field level behavior using Javascript
Conditional printing of certain fields or an entire subform based on a script response to the value of a particular field ??? Is it at all possible in a dynamic PDF file ?
My PDF file works well - but there are certain instances where I would like to be able to skip an iteration of a subform based on the value of certain fields or be able to print a couple of extra fields not normally printed when a particular value is sensed..
Is this kind of thing only possible by manipluating the original XML data to include a trigger or a contrived XML segment that I generate for this reporting purpose ???
smde@adobeforums.com Guest
-
-
smde@adobeforums.com #4
Re: Field level behavior using Javascript
The Answer is : Yes - of course you can -
using something as simple as a switch statement::::::: You can do something like the following.
var IsTestVal = this.boundItem(xfa.event.newText);
var bEnableTextField = true;
switch (IsTestVal)
{
case "Value1": //
TextField1.rawValue = "Stuff for line1:\n- Line2\n- Line3\n- Summary";
break;
case "Value2": //
TextField1.rawValue = "Condition2..."
break;
default: // unknown value -- do nothing
bEnableTextField = false;
break;
}
if (bEnableTextField)
{
TextField1.access = "open"; // enable field
TextField1.caption.font.fill.color.value = "0,0,0"; // set caption to black
}
smde@adobeforums.com Guest



Reply With Quote

