You need to sign in to do that
Don't have an account?

Visualforce Page Redirection from LIST VIEW button with record select message ALERT check
I am finding it very irritating in a situation where I implement a Mass Update Button on a List View tab and I've Set the Button as Visualforce Page redirect then I CANNOT display a Message alert for User to First Select records, the way sControls work, I'm stuck here without any check for that button. And I cannot use scontrols for implementing the button.
Any suggestion or any info when will salesforce allow us to apply a Record Selection validation alert when we implement a List Button with Visualforce page redirect ?
here's one way to do it:
//Execute JavaScript List Buttonvar ids= {!GETRECORDIDS($ObjectType.Contact)}; if(ids.length < 1 ) alert('Please select at least one contact.'); else var mywin = window.open('/apex/mypage?ids='+ids.join(','));
//On Apex init()List<string> IDS = ApexPages.currentPage().getParameters().get('ids').split(',',-2);
All Answers
No idea about the roadmap sorry but as a workaround have you tried using OnClick JavaScript to perform the check for record selection then redirecting the user to the Visualforce page with a URL?
Not the nicest but may work.
here's one way to do it:
//Execute JavaScript List Buttonvar ids= {!GETRECORDIDS($ObjectType.Contact)}; if(ids.length < 1 ) alert('Please select at least one contact.'); else var mywin = window.open('/apex/mypage?ids='+ids.join(','));
//On Apex init()List<string> IDS = ApexPages.currentPage().getParameters().get('ids').split(',',-2);
Hi,
I am new to Visualforce and I am facing similar problem. Could you please post the sample code here with some details how you used the Javascript.
Thanks,
Harsha
I am creating a button called VIEW ALL on the accounts. I need help . The button should display a page that contains all accounts. But VF Page is not available for LIST VIEW.kindly help