2 Replies Latest reply on Dec 2, 2013 12:16 AM by charles.ietswaard1

    Placing two tables with motion graphics

    charles.ietswaard1

      Hi All,

       

       

      I want to place two tables using motion graphics. The tables are generated with value's from one form.  The value's of the form are passed to external scripts with the Scripting.Globals command and then the scripts are called.

       

       

      ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

          Dim cmd, cmd_exe

          Dim ScriptingHome                                                                                                                ' Directory where the scripts are stored

          Dim ScriptFile                                                                                                                       ' The external script to run

       

          ScriptingHome  = "P:\mentor_exp\et_libraries\Automation\PCB_Drawings\"

       

       

          ScriptFile         = "Table1.vbs"

          cmd                 = ScriptingHome&ScriptFile                                                                           ' Creating the path to the external script

          cmd_exe          = application.ProcessScript(cmd,True)                                                            ' Run the external script for Table1

       

       

          Scriptfile          = "Table2.vbs"

          cmd                = ScriptingHome&ScriptFile                                                                           ' Creating the path to the external script

          cmd_exe         = application.ProcessScript(cmd,True)                                                           ' Run the external script for Table 2

       

      ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

       

       

       

      When you only run the script for Table1 or the script for Table2 everything works fine. The motion graphics are created and when the mouse button is clicked the graphics are placed on the drawing.

       

      When you run both scripts from the form, the motion graphics for Table1 are created and the script is waiting for the mouse click. Meanwhile  the second script is called and the motion graphics for table2 are created, clearing the graphics from the first script.

       

      Is there a way to call the script for the first table and wait till it's placed on the drawing and then continue with the second script

       

       

      btw, in both table scripts the Scripting.DontExit is set to true to wait for the mouse click

       

       

      Regards, Charles

        • 1. Re: Placing two tables with motion graphics
          kendall_hiles

            As far as the one script waiting for the other, don't use process script use the WScipt shell Run command and you can google it to see the options

           

          Dim WshShell, objShell

              Set WshShell = CreateObject("WScript.Shell")

              'Set objShell = CreateObject("Shell.Application")

              Dim proj, icdb, log, arg, SDD_env

              SDD_env = Environ("SDD_HOME")

              proj = pcbdoc.ProjectIntegration.ProjectFile

           

              icdb = pcbdoc.Path & "keyin.icdb"

              log = pcbdoc.Path & "fred\ces.log"

              arg = SDD_env & "\ces\win32\bin\ceschk.exe -d " & icdb & " -v -v -log " & log & " -sn PCB_Layout_Temp -topblock pcb -fix -prj " & proj '-clear -prj " & proj

           

           

              DebugPrint "Cleaning CES  " & arg

           

              WshShell.RUN arg, 0, True '1 to see the window True to wait until it finishes

          ---------------------------------------------------------------------------------------------------------------------------------------------------------

           

          There is a good example of motion graphics in AATK.

          LayerStack.jpg

          • 2. Re: Placing two tables with motion graphics
            charles.ietswaard1

            The motion graphics from the the AATK stackup are used as a starting point for the motion graphics of the tables and work fine.

             

            I will work on using the WScript shell run to make it work

             

            Thanks

             

             

            Regards, Charles