11 Replies Latest reply: Jul 30, 2014 1:37 AM by marco.dona.96 RSS

    synchronized scrollbars of differents documents (using FM10)

    marco.dona.96 Community Member

      Someone know how can I move two or more scrollbars of documents in the same FrameMaker process? I tried to search in the web but I found anything.. If someone know the code that I can use, please post it here.

       

      Thank you           -Marco

        • 1. Re: synchronized scrollbars of differents documents (using FM10)
          Russ Ward Community Member

          Marco,

           

          Are you using ExtendScript? If so, the only way I know to move a scrollbar (without programming to the Windows API) is to use the ScrollToText() method. This will scroll a document to a specific spot, more or less. But, you would have to know where you want to scroll to and you would have to be able to respond to a scroll action in another window. I don't know that this is possible.

           

          The more I think about it, this may not be possible using FrameMaker development tools alone. I don't think there is any way to automatically respond to a scrolling action, which would be required to trigger a scroll in another window. Plus, it would be real tricky to figure out how far to scroll, etc.

           

          What is the specific reason you want to do this? Perhaps there is an alternative.

           

          Russ

          • 2. Re: synchronized scrollbars of differents documents (using FM10)
            marco.dona.96 Community Member

            Hi Russ,

             

            The reason because I need to control the scrollbars is that I need to compare many documents (I work with many manuals in more than eight languages), so I need to view if the images are in the same position etc. I would have a system to scroll together the scrollbar of my documents such as the "synchronized scrolling" in MS Word. I wrote about script but I'm not sure that is the best way to resolve my problem, in this world I'm a novice. If you know something better than my ideas please tell me.

             

            Thank you,            Marco

            • 3. Re: synchronized scrollbars of differents documents (using FM10)
              Russ Ward Community Member

              Hi Marco,

               

              Usually, I like to say that anything is possible with scripting, but in this case I see no easy way. I don't really know where I would even start, were it my task to accomplish. My thought is that FrameMaker is simply not designed to readily support this. If I am wrong, I hope someone can step in and correct me. I apologize that I could not provide a more productive answer for you.

               

              Russ

              • 4. Re: synchronized scrollbars of differents documents (using FM10)
                marco.dona.96 Community Member

                Russ,

                 

                I know that with scripting is very difficult resolve this problem but, knowing I'm new in this world, I hoped someone could surprise me with an answer. Now I haven't many skills to talk about scripting with other people but will be my work discover something new and in a near future (I hope) post here the solution about my question because for everyone who work in my same way it's a very time saving.

                Thank you another time for your help.

                 

                -Marco

                • 5. Re: synchronized scrollbars of differents documents (using FM10)
                  4everJang Community Member

                  Hi Marco,

                   

                  I think it is quite possible to do this in scripting, but it would take more than just a few lines of code to make it work. If this is important for you to have, I can work on a solution but I would have to get more specific information from you and I would have to make you a quote for the work. My approach would be to place markers in the original documents (at titles, images, tables), which would survive the translation and possible reuse process. Then it becomes possible to let all open documents scroll to the same markers (if they are available in those documents). As I mentioned, it would involve quite a bit of coding and I have done similar work before, so I do not expect it to be a very costly job. On the other hand, I will not create this in my own time because I am not sure about the market value and cannot currently afford to invest time without getting immediate return on that investment. I hope you understand my position. Just get in touch if you are interested and we can work something out.

                   

                  Kind regards

                   

                  Jang

                  • 6. Re: synchronized scrollbars of differents documents (using FM10)
                    marco.dona.96 Community Member

                    Hi Jang,

                     

                    I know that is a very difficult work and I know that everything have a cost but I wrote my problem in this forum because I needed someone who could give me an hand, so I think that if I have the possibilities to pay someone for this work I would have written my problem to a software house because it's more fast and more reliable.

                     

                    I know that you can't spend your free time to make a program for me, so thank you for all but I can't accept your offer.

                     

                    Thank you      -Marco

                    • 7. Re: synchronized scrollbars of differents documents (using FM10)
                      4everJang Community Member

                      Marco,

                       

                      Although I do understand that you have no budget to spend on this, your idea about software houses being able to do this type of work faster and more reliable is completely off the charts. No "software house" has these skills as they are tied in with thorough knowledge of FrameMaker and the ExtendScript Toolkit. If you do want to find a programmer to create the type of tool you need (which should of course work inside FrameMaker), this forum is the ONLY place on the planet where you will find such programmers. And so far, none of the other experts have indicated that they see a solution.

                       

                      As this is a LOT of work to figure out, I am simply not willing to hand you all that information for free. This means you can either forget about this type of tool or start the long road towards excellence in ExtendScript programming and thorough knowledge about FrameMaker internals until you will be able to write the script yourself. It is just a matter of estimating what the return on investment for this type of script would be for you.

                       

                      I do apologise if I sound a little harsh, but I do not like the implication in your post that a software house would be able to do a better job on this. That does no justice to the skills and knowledge that the experts on this forum have acquired.

                       

                      Kind regards

                       

                      Jang

                      • 8. Re: synchronized scrollbars of differents documents (using FM10)
                        marco.dona.96 Community Member

                        I'm sorry, I didn't want be rude to you. I wrote that I don't know very much about scripting and this is the best example to confirm this.

                        My position about pay someone to resolve my problem stay the same and I'm really sorry about this.

                        I apologize again for disrespect to you and for my impossibility to repay the efforts of someone who could resolve my problem.


                        Kind regards      -Marco

                        • 9. Re: synchronized scrollbars of differents documents (using FM10)
                          marco.dona.96 Community Member

                          Also I know that scripting isn't the only way to answer my question, so I think other people outside this forum could do something to resolve my problem.

                          • 10. Re: synchronized scrollbars of differents documents (using FM10)
                            K.Daube Community Member

                            You can solve the problem with an external script (AutoHotkey script), which sends keystrokes to FM (ah, I'm missing "insert code" in this editor):

                            ScrollBothDn:
                              WinActivate,  ahk_class FrameFamily9.MdiFrame
                              WinActivate,  ahk_class FrameFamily10.MdiFrame
                              WinActivate,  ahk_class FrameFamily11.MdiFrame
                              WinActivate,  ahk_class FrameFamily12.MdiFrame
                              Send, {PgDn}                          ; scroll this down
                              Send, ^{Tab}                          ; switch to other doc window
                              Send, {PgDn}                          ; scroll this down
                              Send, ^{Tab}                          ; switch to first doc window
                            Return
                            
                            ScrollBothUp:
                              WinActivate,  ahk_class FrameFamily9.MdiFrame
                              WinActivate,  ahk_class FrameFamily10.MdiFrame
                              WinActivate,  ahk_class FrameFamily11.MdiFrame
                              WinActivate,  ahk_class FrameFamily12.MdiFrame
                              Send, {PgUp}                          ; scroll this down
                              Send, ^{Tab}                          ; switch to other doc window
                              Send, {PgUp}                          ; scroll this down
                              Send, ^{Tab}                          ; switch to first doc window
                            Return

                            I have implemented this in a small Utility TextHelper .

                             

                            If You want to scroll by page rather by screen (you need to have the same zoom level though) - you can set up a small customui.cfg for the fminit folder:

                            <Modify GotoPreviousScreen<KeySequence /F11>>
                            <Modify GotoNextScreen  <KeySequence /F12>>
                            <Modify GotoPreviousPage <KeySequence /PgUp>>
                            <Modify GotoNextPage  <KeySequence /PgDn>>
                            

                            Klaus Daube

                            • 11. Re: synchronized scrollbars of differents documents (using FM10)
                              marco.dona.96 Community Member

                              I found a solution, who are intresting about it must contact me privately. My email is: marco.dona1996@gmail.com


                              -Marco