Expand my Community achievements bar.

Applications for the 2024-2025 Adobe Experience Manager Champion Program are open!
SOLVED

Dynamic page jump problem

Avatar

Level 4

Hi All

I have been using the following code in a button to jump to a certain section in my form

xfa.host.currrentPage=pagenumber

This is fine in a static form but how can I get the button to go to a particular section in a dynamic form?

Thanks

Darren

1 Accepted Solution

Avatar

Correct answer by
Former Community Member

In a dynamic form you will not know what the page number is so you cannot use that technique....but you can put the cursor in a field using xfa.host.setFocus("fieldName").

I have seen other people put a small 1pixel by 1pixel field on the top of the page (make the field have no borders and have the foreground and background color the same colour as the page) then set your focus to that field. The user will not know it is a field (because it is so small).

Paul

View solution in original post

2 Replies

Avatar

Correct answer by
Former Community Member

In a dynamic form you will not know what the page number is so you cannot use that technique....but you can put the cursor in a field using xfa.host.setFocus("fieldName").

I have seen other people put a small 1pixel by 1pixel field on the top of the page (make the field have no borders and have the foreground and background color the same colour as the page) then set your focus to that field. The user will not know it is a field (because it is so small).

Paul

Avatar

Level 4

That's great.

Many thanks Paul.

Darren

The following has evaluated to null or missing: ==> liqladmin("SELECT id, value FROM metrics WHERE id = 'net_accepted_solutions' and user.id = '${acceptedAnswer.author.id}'").data.items [in template "analytics-container" at line 83, column 41] ---- Tip: It's the step after the last dot that caused this error, not those before it. ---- Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign answerAuthorNetSolutions = li... [in template "analytics-container" at line 83, column 5] ----