Take the 2-minute tour ×
Salesforce Stack Exchange is a question and answer site for Salesforce administrators, implementation experts, developers and anybody in-between. It's 100% free, no registration required.

I want to display flows in lead object direct button no need to use visualforce pages,i think it is possible in javascript can you please suggest me...

Thanks, Bhaskar

share|improve this question

1 Answer 1

Something like this should work. You will obviously have to substitute in your values like your flow name, and the parameters, if any, you want to pass in, but this should get you started.

{!RequireScript("/soap/ajax/29.0/connection.js")}

String base = URL.getSalesforceBaseUrl();
var url = {!base}+encodeURI('/flow/FLOW_NAME&SOME_PARAM={!sObject.Id}&retURL=/{!sObject.Id}');

window.open(url);
share|improve this answer
    
Thank you it's working –  user2232083 Jul 2 at 12:13
    
If it's working, then please mark this as the accepted answer, @user2232083 –  James Loghry Jul 2 at 13:23

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.