Animation in session file

Altair Forum User
Altair Forum User
Altair Employee
edited October 2020 in Community Q&A

Hi,

I have a session file containing 5 pages. To run the animation of all the pages I have to select each page and start the animation.

 

Is it somehow possible in Hyperview to start the animation of all the pages in the session with one click?

 

Thank you in advance.

Bhaumik

Tagged:

Answers

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited May 2018

    Hi Bhaumik,

     

    Please use the below icon to synchronize all the windows at a time.

     

    image.png.f9960b283dc7177719bd66e7485b049a.png

     

    Thank you

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited May 2018

    Hi,

     

    I thought you could only use that button to synchronize windows on the same page. If you want to start animations on multiple pages with one click you will need to use a script. At least that is the only way I know.

     

    Do the animations have to be synchronized?

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited May 2018

    Just as an example. The script could look like this:

     

    hwi GetSessionHandle sess
    sess GetProjectHandle proj

    for {set i 1} {$i<=[proj GetNumberOfPages]} {incr i} {
        proj GetPageHandle p$i $i
        
        set WindowIdList ''
        for {set j 1} {$j<= [p$i GetNumberOfWindows]} {incr j} {
            p$i GetWindowHandle p$i\w$j $j
            if {[p$i\w$j GetClientType] =='Animation'} {lappend WindowIdList $j}
            p$i\w$j ReleaseHandle
            }
        if {[string length $WindowIdList]} {
            p$i AddWindowSyncGroup SyncIt$i $WindowIdList
            p$i SetWindowSyncGroupState SyncIt$i true
            }
        p$i StartAnimation
        unset j WindowIdList
        p$i ReleaseHandle
    }
    unset i
    proj ReleaseHandle
    sess ReleaseHandle