Action Definition: Assessment Test Questions

  1. (Question pool 1) What does an action declaration consist of? Select all applicable members.
    1. A field of the PXButton type
    2. A field of the PXAction<> type
    3. A method that implements the action
    4. A callback for the action
  2. (Question pool 1) Select all correct statements about an action declaration.
    1. An action declaration consists of a field of the PXAction<> type and a method that implements the action.
    2. The field and the method should have the same name, differing only in the capitalization of the first letter.
    3. The field and the method should have the same name, with the same capitalization of the first letter.
    4. An action declaration consists of a field of the PXButton<> type and a method that implements the action.
  3. (Question pool 1) Select all possible forms of declaration of an action method.
    1. Without parameters and returning void
    2. With a parameter of the PXAdapter type and returning IEnumerable
    3. With a parameter of the PXAdapter type and returning void
    4. Without parameters and returning IEnumerable
  4. (Question pool 2) Which form of declaration of an action method should you use for an action that is to be executed synchronously?
    1. Without parameters and returning void
    2. With a parameter of the PXAdapter type and returning IEnumerable
    3. With a parameter of the PXAdapter type and returning void
    4. Without parameters and returning IEnumerable
  5. (Question pool 2) Which form of declaration of an action method should you use for an action that is to be executed asynchronously?
    1. Without parameters and returning void
    2. With a parameter of the PXAdapter type and returning IEnumerable
    3. With a parameter of the PXAdapter type and returning void
    4. Without parameters and returning IEnumerable
  6. (Question pool 3) Suppose that an action will be represented by a button or command on the UI. For the method that implements this action, select all correct statements about the CommitChanges property of the PXButton attribute, that is added to this method.
    1. The CommitChanges property must be always set to true for the action if it causes changes to be saved to the database.
    2. For the corresponding button or command on the UI, the CommitChanges property of the PXButton attribute is set to false by default.
    3. For the corresponding button or command on the UI, the CommitChanges property of the PXButton attribute is set to true by default.
  7. (Question pool 3) Select all purposes that an action can be used for.
    1. To redirect a user to a specific form or report
    2. To modify or validate data records
    3. To start a background operation, which is executed on a separate thread
    4. To handle events
  8. (Question pool 4) What member of a graph contains all PXAction<> objects defined in the graph?
    1. Buttons
    2. AllActions
    3. PXActions
    4. Actions
  9. (Question pool 4) Which items are included in the Actions collection that is available in a graph?
    1. All PXAction<> objects defined in the graph
    2. All commands displayed on the toolbar of the corresponding form
    3. All commands displayed on the More menu of the corresponding form
  10. (Question pool 5) How do you cause a command to be displayed on a toolbar at runtime?
    1. By calling the SetEnabled method
    2. By calling the SetVisible method
    3. By modifying the Visible property in the ASPX file
  11. (Question pool 5) How do you enable an action at runtime?
    1. By calling the SetVisible method
    2. By calling the SetEnabled method
    3. By specifying Enabled=true for the PXUIEnabled attribute
    4. By specifying CommitChanges=true for the PXButton attribute
  12. (Question pool 5) Suppose that a command should become visible when Field1 has a certain value. In which event handler should you change the action visibility?
    1. FieldUpdated
    2. FieldVerifying
    3. RowUpdating
    4. RowSelected
  13. (Question pool 5) Suppose that an action should become available when Field1 has a certain value. In which event handler should you change the availability of the action?
    1. FieldUpdated
    2. FieldVerifying
    3. RowUpdating
    4. RowSelected
  14. (Question pool 6) How do you define a category for a command on the More menu?
    1. By specifying the Category property of the PXButton attribute
    2. By making changes to the ASPX code of the form where the command is displayed
    3. By calling the SetVisible method
  15. (Question pool 6) What do you have to do to place a command on the More menu?
    1. Nothing. The command is placed on the More menu automatically.
    2. Specify the Category property of the PXButton attribute.
    3. Make changes to the ASPX code of the form where the command is displayed.
    4. Call the SetVisible method.
  16. (Question pool 6) How do you place a command on a table toolbar?
    1. Call the SetVisible method
    2. Configure the PXButton attribute of the action
    3. Define the PXToolBarButton element in the ASPX code of the page where the command is to be displayed
  17. (Question pool 6) Suppose that you want to add an action to a form, but you need to hide the button related to this action from the form toolbar and the corresponding command from the More menu. How can you achieve this result?
    1. By setting the DisplayOnMainToolbar property of the PXUIField attribute to false
    2. By setting the DisplayOnFormToolbar property of the PXButton attribute to false
    3. By setting the DisplayOnMainToolbar property of the PXButton attribute to false
    4. By setting the DisplayOnFormToolbar property of the PXUIField attribute to false