Create a Ribbon Button for Model-Driven App | PL-400 Exam Question Answer

Enable Ribbon Button on Main Screen | PL-400 Exam Question Answer

Question

You create a new ribbon button for a model-driven app.

You want the app to enable the button on the main screen when the text field is changed.

And if a user clicks the new button, it opens the web page.

What command button elements should you use to achieve your goal?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D. E.

Correct Answers: B and D

When you create a new command button, you need to address two elements: rule and actions.

The rule defines when button's state within the application, like enable/disable state of the button when some field is changed or who can see the button.

There are two types of rules: enable (should the command button be enabled) and display (should the rule be visible for the users)

The action describes the button behavior, like what should happen when the button is clicked.

There are two types of command button actions that users can define in the OnClick event: execute the custom logic using JavaScript code or open a specific URL.

It can be the dynamic URL if the business logic of your app requires it.

All other options are incorrect.

For more information about the Command button rules and actions, please visit the below URLs:

To achieve the goal of enabling a ribbon button when a text field is changed and opening a web page upon clicking the button, you would need to use the following command button elements:

A. Command Function: This element defines the JavaScript function that runs when the button is clicked. It can be used to perform various tasks like opening a web page, creating a record, or running a workflow. In this case, you would need to define a function that opens the desired web page when the button is clicked.

B. Rule: This element is used to enable or disable a command based on certain conditions. In this case, you would need to create a rule that enables the button when the text field is changed.

C. Call: This element is used to call a function or a rule. In this case, you would need to call the rule that enables the button when the text field is changed.

D. Action: This element is used to perform an action when a rule is triggered. In this case, the action would be to enable the ribbon button.

Therefore, the correct combination of command button elements to achieve the desired outcome would be:

  • Use a Command Function to define a JavaScript function that opens the desired web page upon clicking the ribbon button.
  • Use a Rule to enable the ribbon button when the text field is changed.
  • Use a Call to call the rule that enables the ribbon button when the text field is changed.
  • Use an Action to perform the action of enabling the ribbon button.

Therefore, the correct answer to the question would be a combination of A, B, C, and D: Command Function, Rule, Call, and Action.