set the scollbar to a specific position SOLVED
Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan
Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
set the scollbar to a specific position
Hallo,
I have a one-page document and try to set the scollbar to a specific position.
In the FullDemo application I found no example.
Is that possible and if so, how?
AteBe
I have a one-page document and try to set the scollbar to a specific position.
In the FullDemo application I found no example.
Is that possible and if so, how?
AteBe
- Tracker Supp-Stefan
- Site Admin
- Posts: 17824
- Joined: Mon Jan 12, 2009 8:07 am
- Location: London
- Contact:
Re: set the scollbar to a specific position
Hello AteBe,
Is it that you want to place the scroll bar on a different location than the default (right of the main rendering area), or is it that you want to have the page scrolled down to a specific place?
Regards,
Stefan
Is it that you want to place the scroll bar on a different location than the default (right of the main rendering area), or is it that you want to have the page scrolled down to a specific place?
Regards,
Stefan
Re: set the scollbar to a specific position
Hallo Stefan,
sorry for the unclear question.
I try to scroll the page down to a specific place?
The position of the scrollbar itself is ok.
AteBe
sorry for the unclear question.
I try to scroll the page down to a specific place?
The position of the scrollbar itself is ok.
AteBe
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: set the scollbar to a specific position
Hello AteBe,
To do that, use this method:
https://sdkhelp.pdf-xchange.com/vi ... estination
Cheers,
Alex
To do that, use this method:
https://sdkhelp.pdf-xchange.com/vi ... estination
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: set the scollbar to a specific position
Hallo Alex,
thanks for the example. However, I have problems translating the code into Java.
In the PDFXChange Viewer the following JavaScript was used for setting the scroll Position:
var a = new Object; a.pageViewLayoutMode=2; a.pageViewZoom=114.58000183105467; a.pageViewZoomType=0; a.pageViewRow=0; a.pageViewBX=0; a.pageViewBY=0; a.pageViewX=53.666155326539695; a.pageViewY=250.6981964111328; a.pageViewPageNum=0; this.viewState = a;
According to the post viewtopic.php?f=62&t=30858 every Javascript that worked in the PDFXChange viewer should also work in the PDFXChange Editor.
Can you tell me why it one does not work anymore in the PDFXChange Editor?
AteBe
thanks for the example. However, I have problems translating the code into Java.
In the PDFXChange Viewer the following JavaScript was used for setting the scroll Position:
var a = new Object; a.pageViewLayoutMode=2; a.pageViewZoom=114.58000183105467; a.pageViewZoomType=0; a.pageViewRow=0; a.pageViewBX=0; a.pageViewBY=0; a.pageViewX=53.666155326539695; a.pageViewY=250.6981964111328; a.pageViewPageNum=0; this.viewState = a;
According to the post viewtopic.php?f=62&t=30858 every Javascript that worked in the PDFXChange viewer should also work in the PDFXChange Editor.
Can you tell me why it one does not work anymore in the PDFXChange Editor?
AteBe
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: set the scollbar to a specific position
Hello AteBe,
Does this work in the End-User Viewer and Editor? Also, why are you using the JS if there is an SDK code that should be used instead (there is a sample in the link I mentioned)?
Cheers,
Alex
Does this work in the End-User Viewer and Editor? Also, why are you using the JS if there is an SDK code that should be used instead (there is a sample in the link I mentioned)?
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: set the scollbar to a specific position
Hallo Alex,
I replace in our application the PDFXChange Viewer with the PDFXChange Editor. Therefore I try to set the scrollbar in the PDFXChange Editor.
Since our application is developed in Java, I've tried to translate the example you've sent me into Java.
Unfortunately, I did not manage that. So the alternative would be Javascript.
Or do you know what the sample code looks like in Java?
AteBe
I replace in our application the PDFXChange Viewer with the PDFXChange Editor. Therefore I try to set the scrollbar in the PDFXChange Editor.
Since our application is developed in Java, I've tried to translate the example you've sent me into Java.
Unfortunately, I did not manage that. So the alternative would be Javascript.
Or do you know what the sample code looks like in Java?
AteBe
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: set the scollbar to a specific position
Hello AteBe,
I see. Sadly there is no sample in Java. Try using your JS in both End-User Editor and Viewer and see whether it works.
Cheers,
Alex
I see. Sadly there is no sample in Java. Try using your JS in both End-User Editor and Viewer and see whether it works.
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: set the scollbar to a specific position
Hallo Alex,
I tried that. Unfortunately, the following JavaScript does not work either.
var a = new Object; a.pageViewLayoutMode=2; a.pageViewZoom=114.58000183105467; a.pageViewZoomType=0; a.pageViewRow=0; a.pageViewBX=0; a.pageViewBY=0; a.pageViewX=53.666155326539695; a.pageViewY=250.6981964111328; a.pageViewPageNum=0; this.viewState = a;
Do you have any idea why?
AteBe
I tried that. Unfortunately, the following JavaScript does not work either.
var a = new Object; a.pageViewLayoutMode=2; a.pageViewZoom=114.58000183105467; a.pageViewZoomType=0; a.pageViewRow=0; a.pageViewBX=0; a.pageViewBY=0; a.pageViewX=53.666155326539695; a.pageViewY=250.6981964111328; a.pageViewPageNum=0; this.viewState = a;
Do you have any idea why?
AteBe
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: set the scollbar to a specific position
Hello AteBe,
Just tried your script in the End-User Editor - from what I see, it moved the page position along with zoom.
Cheers,
Alex
Just tried your script in the End-User Editor - from what I see, it moved the page position along with zoom.
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: set the scollbar to a specific position
Hallo Alex,
I also tried the script in in the End-User Editor an nothing happend.
Is there a way to get log-informations to find out, what went wrong with my call?
AteBe
I also tried the script in in the End-User Editor an nothing happend.
Is there a way to get log-informations to find out, what went wrong with my call?
AteBe
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: set the scollbar to a specific position SOLVED
Hello AteBe,
I opened a multi-page document, copied your script, opened the JS Console (Ctrl+J) pasted it there and ran it - the left top corner is 53/250 zoom is 6400 and the pages layout is Continuous. Make sure that you have the JS Enabled: Cheers,
Alex
I opened a multi-page document, copied your script, opened the JS Console (Ctrl+J) pasted it there and ran it - the left top corner is 53/250 zoom is 6400 and the pages layout is Continuous. Make sure that you have the JS Enabled: Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ