Automic Workload Automation

 View Only

Setting parameters on tasks started from task pre- and post-conditions

  • 1.  Setting parameters on tasks started from task pre- and post-conditions

    Posted Dec 05, 2022 08:10 AM
    Edited by Michael A. Lowry Dec 05, 2022 08:43 AM

    In task pre- and post-conditions, the START OBJECT action can be used to execute a named object.

    When you select an executable object that has a prompt set attached and click Accept, the word <PARAMETERS> will become highlighted in orange.

    Click on the word and you will be able to supply values for the prompt set variables.

    When you then click Accept, you will not see the values indicated in the list of conditions and actions - only the generic text <PARAMETERS>. However, if you did it correctly, the parameters will have been saved. You can view or edit them by clicking <PARAMETERS> again.

    I discovered an undocumented capability. Once you have set parameters for the object to execute, you can replace the object name with a variable name. Provided the variable resolves at runtime into the name of an object that has the same prompt set variables, it will work.

    The only downside is that the parameters will not be directly editable unless the object-to-execute is an actual object name with a prompt set attached. (A work-around is to edit them in XML.)

    ...
    <action active="1" id="EXECUTE OBJECT" once="1" type="A" uiinfo="">
      <params>
        <param altview="0" name="XC_P01" type="V" value="&amp;PRPT_REMOTE_TASK_EXEC_OBJ#"/>
        <param altview="0" name="XC_P02" type="S" value="&lt;PARAMETERS&gt;"/>
        <param altview="0" name="XC_P03" type="V" value="##911011">
        <param name="PRPT_VAR_1s.00" value="1" vname="XC_P03"/>
        <param name="PRPT_VAR_2s.00" value="2" vname="XC_P03"/>
        <param name="PRPT_VAR_3s.00" value="3" vname="XC_P03"/>
        </param>
        <param altview="0" name="XC_P04" type="V" value=""/>
      </params>
    </action>
    ...


    (I just noticed that the XML export contains an extraneous unmatched </param>. Perhaps someone from Broadcom can look at this and see if it's a bug.)