You need to sign in to do that
Don't have an account?

Can I get a selected record type before insert the new record?
Hello.
I made two record types.
When I select the first record type, I'd like to create a new record in a A page with some detail information and
If I select the second record type, I'd like to create a new record in a A page without detail information.
( A page is visualforce page or lightning component, not page layout)
So, to make this process, I need to know the selected record type information.
Because, depends on the record type, I will hide some lightning component items.
But I have no idea about this.
is it possible??? please help me .
I made two record types.
When I select the first record type, I'd like to create a new record in a A page with some detail information and
If I select the second record type, I'd like to create a new record in a A page without detail information.
( A page is visualforce page or lightning component, not page layout)
So, to make this process, I need to know the selected record type information.
Because, depends on the record type, I will hide some lightning component items.
But I have no idea about this.
is it possible??? please help me .
May I suggest you please refer to below link with a similar discussion which should help you further.
- https://salesforce.stackexchange.com/questions/149647/get-selected-record-type-before-insert-using-apex-trigger
Kindly mark this as solved if the reply was helpful.Thanks,
Nagendra
For that you no need to do any custom code ..
Component visibility properties appear when you select a component on a record, app, or Home page in the Lightning App Builder. This behavior applies to standard components, custom components, and components from AppExchange. No need to do anything to your custom components. It’s all handled by the Lightning App Builder.
Refer this link
https://help.salesforce.com/articleView?id=lightning_page_components_visibility.htm&type=5