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
BonaaBonaa 

Embedded the lightning component in visualforce page, then the lookup search window is not popping up

Hi 
I have created a lightning component and embedded in Vf page.
It has a field for acoount lookup.When I search for an account name, I will get the five account names not the account name I am searching.
When I use the same component without the the VF page, and when I do search  the search window will pop up with all the results.
Tried with lightning:inputField and force:inputField.
How we can achieve the same functionality in Visualforce page+lightning component

 
Ashif KhanAshif Khan

Hi Bonaa.

force:inputField only works in the pure lightning component. When you embed component in VF page it will not work.

The only solution is you have to use custom lookup field in the lightning component that you can embed that component in VF page.

This is the custom lookup link
http://sfdcmonkey.com/2017/07/17/re-usable-custom-lookup/