Facility Control

 View Only
  • 1.  Simple Data Entry to a table or grid

    Posted 03-22-2022 17:44

    Hi

    Are there any examples, code snippets, etc. showing:

    -Creating a table of n columns where I can manually enter table content (I know - what is this type info in stuff?)
    -Being able to add and/or delete rows
    -pick a row and selectively store individual column data to a variable

    Any direction, comments(helpful) on the above would be greatly helpful to an extreme non-programmer (but a decent monkey-see / monkey-do person)



    ------------------------------
    JerryB
    ------------------------------


  • 2.  RE: Simple Data Entry to a table or grid

    Ross Staff
    Posted 04-06-2022 06:42
    Hey Jerry
     
    In the example below I have built some table types. The first "Table" sets our each row with a <tr> tag and all the collums sit within. The second is our simple grid which lays out objects in order from left to right till the collum limit is hit then lays out the next item on the next line. These are mainly for layout and display though. 

    The one i suspect your more interested in is the parameter table. This combines 3 parameters to display them as a table.  So you will see I have created left middle and right as params and have combined them in order i wanted the columns in a separate param. 
    When this is applied to the canvas with the table constraint applied it displays as a table. This now has lots of options and wonderful things you can do with it and your params. I've added an option to reorder the rows on the table for you to play with. Manipulating the parameters allows you to change the table. I cant find a clean example right now but I will try and post one here later. But hopefully that gets you started. 


    J


    <abs contexttype="opengear" id="_top" keepalive="false">
       <label header="true" height="82" left="207" name="Param Table" style="txt-align:west" top="484" width="333"/>
       <label header="true" height="87" left="835" name="Simple Grid Tool" style="txt-align:west;" top="30" width="534"/>
       <label header="true" height="75" left="196" name="Table Tool" style="txt-align:west;" top="32" width="359"/>
       <meta>
          <params>
             <param access="1" maxlength="0" name="Left Column" oid="Left" precision="0" type="STRING_ARRAY" widget="default">
                <value>Left Top</value>
                <value>Left Middle</value>
                <value>Left Bottom</value>
             </param>
             <param access="1" maxlength="0" name="Right Column" oid="Right" precision="0" type="STRING_ARRAY" widget="default">
                <value>Right Top</value>
                <value>Right Middle</value>
                <value>Right Bottom</value>
             </param>
             <param access="1" maxlength="0" name="Middle Column" oid="Middle" precision="0" type="STRING_ARRAY" widget="default">
                <value>Middle Top</value>
                <value>Middle Middle</value>
                <value>Middle Bottom</value>
             </param>
             <param access="1" constrainttype="STRING_CHOICE" name="Table" oid="0x2" precision="0" type="INT16" value="1" widget="table">
                <constraint>Left</constraint>
                <constraint>Middle</constraint>
                <constraint>Right</constraint>
             </param>
          </params>
       </meta>
       <table height="419" left="122" top="97" width="638">
          <tr>
             <label colspan="1" fill="both" name="Top Left" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
             <label colspan="1" fill="both" name="Top Middle" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
             <label colspan="1" fill="both" name="Top Right" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
          </tr>
          <tr>
             <label colspan="1" fill="both" name="Middle Left" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
             <label colspan="1" fill="both" name="Middle Middle" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
             <label colspan="1" fill="both" name="Middle RIght" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
          </tr>
          <tr>
             <label colspan="1" fill="both" name="Bottom Left " rowspan="1" style="txt-align:west;" weightx="1.0" weighty="1.0"/>
             <label colspan="1" fill="both" name="Bottom Middle " rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
             <label colspan="1" fill="both" name="Bottom Right" rowspan="1" style="txt-align:west" weightx="1.0" weighty="1.0"/>
          </tr>
       </table>
       <simplegrid cols="3" height="421" left="851" rows="3" top="100" width="639">
          <label name="Top Left" style="txt-align:west"/>
          <label name="Top Middle" style="txt-align:west"/>
          <label name="Top Right" style="txt-align:west"/>
          <label name="Middle Left" style="txt-align:west"/>
          <label name="Middle Middle" style="txt-align:west"/>
          <label name="Middle Right" style="txt-align:west"/>
          <label name="Bottom Left" style="txt-align:west"/>
          <label name="Bottom Middle" style="txt-align:west;"/>
          <label name="Bottom Right" style="txt-align:west"/>
       </simplegrid>
       <param expand="true" height="105" left="93" oid="0x2" showlabel="false" top="587" width="564">
          <config key="w.reorder">true</config>
       </param>
    </abs>
    ​


    ------------------------------
    Jack Horry
    Product Manager
    DashBoard, Interstellar, PowerPlay, Lightning
    Ross Video | Living Live
    ------------------------------



  • 3.  RE: Simple Data Entry to a table or grid

    Posted 04-06-2022 11:56

    Thanks Jack,

    It's these basic samples that really help me figure out the scripting guide - I've attached what I have accomplished (cobbled together from others samples and questions along with the panel samples from Ross). I know it was written TERRIBLY inefficiently, but it works and if you look at it (no rush) and could suggest some refinements, I'd appreciate it.

    I've left some code in place, just commented out and also a lot of unused param tags sprinkled liberally throughout my mess -- apologies in advance.



    ------------------------------
    JerryB
    ------------------------------



  • 4.  RE: Simple Data Entry to a table or grid

    Posted 04-06-2022 12:11
      |   view attached

    OK - I tried to upload a .grid file (doesn't allow it) so here is the code attached renamed with a .js extension.
    just change the extension to  .grid and that should be the panel.

    -Jerry



    ------------------------------
    JerryB
    ------------------------------

    Attachment(s)

    js
    CustomPlayoutControl.js   119 KB 1 version


  • 5.  RE: Simple Data Entry to a table or grid

    Ross Staff
    Posted 04-06-2022 12:46
    This tutorial walks you through making a table (that's used for a rundown).

    Creating Rundowns
    Ross Video remove preview
    Creating Rundowns
    Controlling many pieces of equipment at the same time during a production can be difficult. Rundowns allow you to setup presets ahead of your production and recall them at the appropriate times. This video will show you how to create and operate a rundown in your DashBoard panel.
    View this on Ross Video >



    ------------------------------
    Ben Gatien
    Ross Video
    ------------------------------



  • 6.  RE: Simple Data Entry to a table or grid

    Posted 04-06-2022 13:04
    Thanks Ben - great tutorial that explains concepts of functions quite well.

    ------------------------------
    JerryB
    ------------------------------



  • 7.  RE: Simple Data Entry to a table or grid

    Ross Staff
    Posted 04-06-2022 13:13
    Hey Jerry. 

    Looks like your all set. We sadly cant look at whole panels to suggest refinements without specific questions on this forum. If you are still in need of help we can look at purchasing some services or training to help you. But i think with the information that Ben has provided in the Dashboard U video you will get to  what your loooking for.

    Jack

    ------------------------------
    Jack Horry
    Product Manager
    DashBoard, Interstellar, PowerPlay, Lightning
    Ross Video | Living Live
    ------------------------------



  • 8.  RE: Simple Data Entry to a table or grid

    Posted 04-09-2022 12:32
    Thx

    ------------------------------
    JerryB
    ------------------------------