function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Neha Srivastava 4Neha Srivastava 4 

I have inline visualforce page, in that i am using "window.parent.location.href" to open child record. I want to make it lightning compatable. I am new to lightning. Can anyone know how to change it to use in lightning?

Narender Singh(Nads)Narender Singh(Nads)
Hi Neha,
Navigating in lightning is done a little bit differently. Salesforce do not encourage the navigation using 'window.location'.
Try using:
force:navigateToComponent (Beta)
force:navigateToList
force:navigateToObjectHome
force:navigateToRelatedList
force:navigateToSObject
force:navigateToURL

You can refer Lightning developer guide for more understanding: https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/ref_force_navigateToComponent.htm

Let me know if it helps.
Thanks!
Neha Srivastava 4Neha Srivastava 4
It got solved.
Narender Singh(Nads)Narender Singh(Nads)
If you found my answer helpful then please mark it as the best answer.
Thanks.