Adobe Livecycle DesignerとXMLファイルを使用して、プロジェクトのPDFフォームを作成しています。XSDを作成しました。これには、次のような無制限の選択肢のシーケンスが含まれています。
<xs:sequence maxOccurs="unbounded">
<xs:choice>
<xs:element name="Item1" type="xs:string" />
<xs:element name="Item2" type="xs:string"/>
</xs:choice>
</xs:sequence>
これをAdobeLivecycleDesignerで表すために、次のようなものがあります。
MyForm (Subform)
ItemsSubForm (Subform, repeated for many items)
Item1Wrapper (Subform)
Item1 (TextField)
Item2Wrapper (Subform)
Item2 (TextField)
AddItemsButtonsSubForm
AddItem1Button (Button)
AddItem2Button (Button)
誰かがPASSWORD1Buttonを押すと、次を使用して新しいItemsSubFormインスタンスを作成します。
this.parent.parent._ItemsSubForm.addInstance();
xfa.resolveNode("this.parent.parent.ItemsSubForm[" +(this.parent.parent.ItemsSubForm.instanceManager.count - 1) + "]").Item2Wrapper.presence = "hidden";
そして、PASSWORD2Buttonの反対のこと。
問題は、アイテムを手動で挿入する以外に、XMLファイルも使用できるようにしたいということです。そのため、上記のXSDを作成しました。また、バインディングを使用して、XSDのItem1要素とItem2要素をそれぞれItem1WrapperとItem2Wrapperに関連付けます。問題は、XMLにItem1要素を含めると、Item1WrapperとItem2Wrapperの両方が作成されることです(Item2でも同じです)。それぞれのラッパーを非表示にするためにロードを制御する方法はありますか?
残念ながら、PDFFormもXSDも変更できません。