You need to sign in to do that
Don't have an account?
'Record Type ID: this ID value isn't valid for the user:' error occurs in Lightning mode for Opportunity creation on VF page.
Hi,
We are using standard Salesforce action ($Action.Opportunity.New) on custom VF page for Opportunity creation. It works fine in Classic mode but not in Lightning mode. In Lightning mode it shows record type selection. It allows to select avaialble record type. On clicking continue it shows record creation popup, but inside popup it always shows page layout assigned for master record type. Then on clicking save button it shows 'Record Type ID: this ID value isn't valid for the user:'.
Please, can anyone help me?
We are using standard Salesforce action ($Action.Opportunity.New) on custom VF page for Opportunity creation. It works fine in Classic mode but not in Lightning mode. In Lightning mode it shows record type selection. It allows to select avaialble record type. On clicking continue it shows record creation popup, but inside popup it always shows page layout assigned for master record type. Then on clicking save button it shows 'Record Type ID: this ID value isn't valid for the user:'.
Please, can anyone help me?
It sounds like you have some automation in place that is trying to change the record type of the Opp. Check for Processes or Workflow Rules that have been defined which might be causing the issue.
For more information may I suggest you please check with below link with similar issue.
- https://success.salesforce.com/answers?id=90630000000Zi1qAAC
Please let us know if you are looking for something else.Kindly mark this as solved if it's resolved.
Best Regards,
Nagendra.
There is no Processes or Workflows have been defined in the organization. Same VF page works fine in Classic Mode, but not working in Lightning Mode.
And suggested link is similar but no one gave appropriate answer.
I am also having same issue, on url direction - working fine in classic, but not in lightning. thorugh everything is same and perfect.
can you just tell me the solution what you have.
Weer you able to find a solution to that? I am having same issues.
We are also experiencing the same issue. Is there any workaround or solution?.
I have raised this issue to salesforce support. They are looking into it. As soon as I get reply I will post here.
Any feedback from Salesforce support yet? I`m having the same issue with Case creation.
The problem is that when you override a standard action with a custom visualforce page, in Lightning Experience it will still use the Classic interface for the record type selection page and the selected record type does not get passed on to the Lightning new record form afterwards, so the record type field will remain empty and it gives that error. One workaround is to fetch and store the record type in the APEX class and then pass it on to the Lightning form using JavaScript.
Class: VisualForce page:
So this way once the record type is chosen, the APEX class will be initialized and the code above will check if the user is in Lightning. If so, it will fetch the record type Id and store it in variable 'chosenRecordType'. Then the script on the VisualForce page will open the Lightning new record form and pass along the record type Id.
Hope this helps! :)
I had the same error with an automated process & two custom objects and found an easier solution. I gave the object a default record type on profile level and it works just fine now!
Cheers