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
beatitbeatit 

How to convert a Text field to Look up in VF

Hi

 

I created a custom text field named Plot S.no ,i created a custom button Transfer ,when clicked opens a VF page with Plot sno,here i wanted plot sno as Look up field....

 

Any ideas please...!?

Pradeep_NavatarPradeep_Navatar

you can make a textfield as a lookup field by creating a image of lookup and invoke a javascript onclick event on that lookup.

 

var url = '/apex/openpop?core.apexpages.devmodeurl?id={!contact.id}'

<img src="/s.gif" onclick="window.open(url,"Lookup","resizable=yes,status=yes,scrollbars=yes,width=400,height=200,target=_blank")">

 

Hope this helps.

beatitbeatit

hi 

 

had Plot sno as text field in plot object,and i had custom button TRANSFER in plot page layout,when i click that i need to get plot sno as Lookup type 

 

is there any way please help me