0

I have a RestrictionRule set up on a custom object that compares a number field on said object to a custom number field on the current User ($User) record. The rule operates as expected for existing records - they can see exactly the records they should, but when the users for whom the rule applies attempt to create a record (with values that would grant them continued access to the record), they receive this error:

enter image description here

Are Users that have RestrictionRules applied to them just unable to create records? Any ideas on how to get around this would be appreciated. This was done on the standard lightning "new record" form.

6
  • Could you apply a validation rule in a step before this one? So you can only block the field display maybe...
    – Cline
    Feb 8, 2022 at 4:15
  • @Cline what would a validation rule accomplish? even testing it with known-good values, and allowing the user to provide a known-good value, this message still appears. Feb 9, 2022 at 15:15
  • Validation rules have specific methods for cases where the data is new (ISNEW()) or just being changed (ISCHANGED()). You can specify whether a given profile can edit or create a record. help.salesforce.com/s/…
    – Cline
    Feb 9, 2022 at 15:24
  • That works for editing, but I need to restrict viewing as well. Users that don't match the fields should not be able to read, edit, or delete said records. Feb 9, 2022 at 18:03
  • For view records you can create a Profile and put the user there. So you can configure the view settings there.
    – Cline
    Feb 10, 2022 at 12:07

0

You must log in to answer this question.

Browse other questions tagged .