Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.

Fit Width and show bookmarks

Avatar

Former Community Member
is there a way to make all forms built in Designer to open in fit width mode? Cant do this with designer forms as the properties are greyed out. Please advise. Also how to show bookmark pane open by default.
4 Replies

Avatar

Former Community Member
Use the zoomType property of the document object.



However if you try it in Designer on any init event, it will fail with InvalidSetError. This property is not available until after init is complete. So you will need to set a timeout to tell PDF to fire the command after everything has initialised properly



app.setTimeOut('this.zoomType = zoomtype.fitW;', 1);



Not sure about opening bookmark window though. Dont think there is anything in JS that can do this.

Avatar

Former Community Member
I am trying to have most pages of a form zoom-to-page while the last page is zoom-to-width. I have tried "this.zoomType = zoomtype.fitW" by attaching it to a subforms docReady, enter, and initialize (with the TimeOut) but no luck. I also attached it to the enter event of the first field with no luck.



At what level (subform, field) and what event (docReady, enter) should I use the zoomType command?



(Although I am creating this in Designer 8, I have to save it as Acrobat 6 for compatibility. Does this matter?)

Avatar

Former Community Member
I tested the script David posted, I placed it in the initialize event at the form level and it worked fine. I don't know about the acro 6 compatibility though, I'm on acro 7 and can't test it.

Avatar

Former Community Member
I tested his script too and it does work at the highest level in the hierarchy. But trying to change the zoom at the subform level from page to page doesn't seem to work.