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
AbAb 

displaying and letting user use lookup on a page designed from visual force page

Hello,

I have a lookup field, but it is not working in Visualforce page,
Is there any way to do it ?

​thanks for suggestions !
Best Answer chosen by Ab
Joseph BauerJoseph Bauer
Yes, you can reference the field name of the object when using a controller extension:
 
<apex:page standardcontroller="opportunity" extensions="extController">
  <apex:inputfield value="{!opportunity.accountid}"/>
<\apex:page>
Then in your extension controller you can get this field in apex and use it anywhere in your code