Expand my Community achievements bar.

Enhance your AEM Assets & Boost Your Development: [AEM Gems | June 19, 2024] Improving the Developer Experience with New APIs and Events

Tab Ordering for Hidden (Excluded Objects) in the Flowable Dynamic PDF

Avatar

Level 3

Hello everyone,

 

I am encountering an issue with my dynamic PDF form that includes numerous subforms, some of which are initially excluded from the layout. The visibility of these subforms is dependent on the values of checkbox, dropdown, or textbox fields.

 

My challenge arises when attempting to establish a logical tab order within the form. The tab order doesn't behave as expected for dynamically hidden and then visible subforms. I've tried a couple of approaches without success:

 

  1. Changing Tab Order with Visible Fields:

    • I made all fields visible (including the hidden one to).
    • Adjusted the tab order as needed.
    • Excluded the unnecessary fields (those are related to condition) from the layout.

    Unfortunately, this method did not yield the expected tab order when subforms became visible based on the values of other fields.

  2. Using setFocus() in Events:

    • I attempted to use the setFocus() function within mouseExit/exit events to influence tab order dynamically.

    This also did not produce the desired result.

Say for example, in the Clear (mouseExit/exit), I used the below code to go Partly Cloudy but it is going to the Fog as based on the tab order Fog comes after Clear

 

0experience_0-1701790603892.png

 

0experience_1-1701790615718.png

 

xfa.host.setFocus(xfa.form.form1.Page_1.Environment_Subform.CheckBox2[0]);

 

I'm reaching out to seek your insights into why this might be happening and to explore potential solutions. If anyone has experience with dynamic PDF forms and tab order management in such scenarios, your guidance would be highly appreciated.

 

Thank you

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

4 Replies

Avatar

Level 3

Greetings,

 

The issue with your Clear and Fog checkboxes is that the Fog Checkbox is visibly higher vertically than all the other checkboxes. When objects are in positioned subforms the tab order reads the vertical position of objects from left to right. So if your placement of objects is off the tab order is off.

 

The solution for your Clear and Fog checkboxes is to place all the objects inside a flowed container - a subform. You will have to manipulate the size of the checkboxes to get them to position the same inside a flowed container. If you do that you will not need the setFocus() code.

 

 

Avatar

Level 3

@koolForms thanks for your reply and for suggestions. 

Do you have any thought about the hidden objects?

Avatar

Level 3

Without being able to see how you have structured your form it will be hard to provide any help on hidden and visible subforms.

The key is that everything should be flowed to ensure proper tabbing.

If you could provide examples of what is happening when a subform is hidden, then visible, as it pertains to the changes in tab order that would be helpful.

Avatar

Level 3

@koolForms thanks for your reply. Yes it is difficult to give suggestions without knowing structure. My form is pretty complex (contains a lot of nested subforms).

 

Just wondering how we can use flowed for every objects. Sometimes, we do also need a positioned subform to place object side by side, right?

I am just using the Designer only for a couple of days (so certainly I am a newbie, and I don't know a lot of things)