Given the following code snippet, that is part of a custom controller for a Visualforce page: In which two ways can the try/catch be enclosed to enforce object-level permissions and prevent the DML statement from being executed if the current logged- in user does not have the appropriate level of access to the object? (Choose two.)

QuestionsCategory: CRT-450Given the following code snippet, that is part of a custom controller for a Visualforce page: In which two ways can the try/catch be enclosed to enforce object-level permissions and prevent the DML statement from being executed if the current logged- in user does not have the appropriate level of access to the object? (Choose two.)
Admin Staff asked 4 months ago
Given the following code snippet, that is part of a custom controller for a Visualforce page:
 Image
In which two ways can the try/catch be enclosed to enforce object-level permissions and prevent the DML statement from being executed if the current logged- in user does not have the appropriate level of access to the object? (Choose two.)

A. Use if(thisContact.OwnerId == User.Info.getUserId())

B. Use if(Schema.sObjectType.Contact.isAccessible())

C. Use if(Schema.sObjectType.Contact.fields.Is_Active__c.isUpdateable())

D. Use if(Schema.sObjectType.Contact.isUpdateable())








 

Suggested Answer: BD

Community Answer: BD



This question is in CRT-450 Salesforce Certified Platform Developer I Exam
For getting Salesforce Certified Platform Developer I











Disclaimers:
The website is not related to, affiliated with, endorsed or authorized by Salesforce. 
Trademarks, certification & product names are used for reference only and belong to Salesforce.
The website does not contain actual questions and answers from Salesforce's Certification Exams.

Next Post

Recommended

Welcome Back!

Login to your account below

Create New Account!

Fill the forms below to register

Retrieve your password

Please enter your username or email address to reset your password.