admin管理员组文章数量:1307949
I'm trying to make a dynamic PDF form using Adobe LiveCycle designer and have a problem. I have a boolean checkbox field that decides if other text fields are required or optional. I'd like to implement this functionality using form scripting - in the 'changed' event of the checkbox field I'd like to modify other form fields so they bee either required or optional. My problem is that I don't know the javascript API and can't find how to modify field 'requiredness'. Thanks for help R
BTW - I'm a beginner ind Adobe's PDF tools but this software is ] a big disappointment for me... And the developer documentation is so weak. Do you know any good online documentation of PDF forms javascript API?
Update: I know how to mark a field required - by setting its mandatory property to mandatory="error". But don't know how to make the field optional.
I'm trying to make a dynamic PDF form using Adobe LiveCycle designer and have a problem. I have a boolean checkbox field that decides if other text fields are required or optional. I'd like to implement this functionality using form scripting - in the 'changed' event of the checkbox field I'd like to modify other form fields so they bee either required or optional. My problem is that I don't know the javascript API and can't find how to modify field 'requiredness'. Thanks for help R
BTW - I'm a beginner ind Adobe's PDF tools but this software is ] a big disappointment for me... And the developer documentation is so weak. Do you know any good online documentation of PDF forms javascript API?
Update: I know how to mark a field required - by setting its mandatory property to mandatory="error". But don't know how to make the field optional.
Share Improve this question edited Nov 7, 2011 at 19:41 nightwatch asked Nov 7, 2011 at 19:25 nightwatchnightwatch 1,4042 gold badges19 silver badges27 bronze badges 1- [enter link description here][1] [1]: stackoverflow./questions/27960808/… Please help me here , i am stuck here and its urgent now – pushkar kumar Commented Jan 15, 2015 at 10:58
2 Answers
Reset to default 6To make a field be optional you set the mandatory property of the object to "disabled"
Ex: displayObject.mandatory = "disabled"
To do so on a condition you do:
field.mandatory = (radioGroup.rawValue == 1) ? "error" : "disabled"
Where field is the field you are making required/optional and radioGroup is a conditional. In your case it would be myCheckbox.rawValue == 1
Try doing:
this.getField("Field Name").required = false;
or:
this.getField("Field Name").required = true;
版权声明:本文标题:javascript - Adobe LiveCycle designer - form scripting - changing the field from optional to required - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741854684a2401271.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论