Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Floating Button Panel on the form

Level 7
Level 7


I want to design a FLOATING Panel for the action buttons on the form. So if i scroll form up or down ,The panel should float on different pages but at the bottom of the page.


I am designing above action buttons: Panel so that user sees these functionalities on every page at the bottom where he scrolls.

Please let me know your ideas how do i do it.

Please let me knw if I could explain my requirement clearly.



3 Replies
Level 8
Level 8

Your question intrigued me, so I sought out to see if it's possible. The issue is, you can get the properties of where you are on the page when you scroll but unfortunately there are no events that fire when you do the scrolling. No event, no code execution to move the buttons.

So I put the code to move the buttons in a setInterval timer at form load and the performance is pretty bad (depending on the refresh rate). I'm still working on it.

In the mean time, can put the subform of buttons on the bottom of your masterpage...


Level 8
Level 8

OK. I have a working example that you can find here:

Here is the code I put in the docReady event of the Main subform (any object will do):

global.timer = app.setInterval(

"var curView = eval(this.viewState.toSource());"+

"yPos=curView.pageViewY>=0 ? (curView.pageViewY+4)*.655/curView.pageViewZoom:0;"+

"xfa.form.form1.pageSet.Page1.all.item(curView.pageViewPageNum).Buttons.y = yPos+\"pt\";",1000);//Change the refresh rate here (in milliseconds)

Every second the above code determines where the top of the form view is and based on the zoom, it determines the y coordinate for the 'floating' object to move. The .655 constant is what I've determined to be the relationship between the pageViewY's units and point units.

The object that this code is moving is a subform with buttons that is on masterpage Page1.

This particular code keeps the buttons at the top. It would take a little while longer to keep them at the bottom, since you'd really have to account for zoom and the page size. Probably getting the media box quads relative to the application window (haven't looked too far into it).

Also, there is a stop button to stop the timer with the same code in the docClose event of the Main subform:


delete global.timer;

Of course the annoying part is having the hourglass appear every once and awhile but unless the event model is updated in future releases to include scrolling, this is how it has to be done.

Hope this helps you and others. I had fun figuring it out.


Level 7
Level 7

Thanks alot Kyle for your help.

This solution would be helpful for achiving similar functionality that i mentioned above but not the exact functionality that i am expecting as adobe designer is deficient of "scroll up event" but i find it realy usefull.

thanks alot for your help once again. tc