Exam PDII Topic 1 Question 187 Discussion

Actual exam question for Salesforce's PDII exam
Question #: 187
Topic #: 1
Consider the Apex controller below, that is called from an Aura component.

What is wrong with this code?

Suggested Answer: C Vote an answer

The method defined in the Apex class must be static to be used as an Aura-enabled method. Aura-enabled methods need to be static because they are called by the Lightning framework without instantiating the class.
References: Apex Developer Guide - Exposing Apex Methods to Lightning

by Wordsworth at Dec 05, 2025, 04:19 AM

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
Nick name: Submit Cancel
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

0
0
0
10