We have a custom detail page button that passes the object id to a VF page which then renders a visual workflow based on that ID.

Salesforce did support URL buttons in lightning before, but it seems to have been axed in spring '16. Now both onClick JS AND URL buttons do not work. The only one that works now is just VisualForce page, and I don't see any way to pass the object ID that way.

I thought about using the window.referrer method, as the object ID is in the url, but salesforce has an intermediary page between the button and the VF page, which takes out that solution.

How can I pass the object ID to the VF page?


1 Answer 1


If all I'm trying to get is the source object (and fields on the source object), it seems I can do that with a custom action, as described here:


To get the object:

public getObj(ApexPages.StandardController controller) {
  parent = controller.getRecord();

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .