+ Start a Discussion
Anushka Bansal 4Anushka Bansal 4 

hyperlink in formula fields

I Have a formula field with a hyperlink as below
HYPERLINK("/"+ Product_Code__c , Product_Code__r.ProductCode)
In my apex code I need to assign the value of this field to a variable but when I debug this variable it shows a value as
partNumber=<a href="/01t50000002NUfX" target="_blank">PBF012D3-03</a>

I want to assign the value to the variable, not in the form of a url.

Zhen Yueh LeanZhen Yueh Lean
Hi Anushka, are you trying to assign a value to a variable in a formula field? I don't think you can achieve that in salesforce. Maybe you want to explain more on your issue?
Ramakrishna Reddy GouniRamakrishna Reddy Gouni
just use Product_Code__c. if you choose hyperlink it embbed hyperlink html code to variable