You need to sign in to do that
Don't have an account?
vickySFDC
How to Pass parameters while click image in my page?
Hi All,
I have requirement clicking image in VF page then it should display list of records .How to pass parameters in clicking on Image in VF and Apex?
Thanks,
vicky
I have requirement clicking image in VF page then it should display list of records .How to pass parameters in clicking on Image in VF and Apex?
Thanks,
vicky
You can create this image as a custom button and then call a function in the controller to doisplay the list of records.
Check the link below to understand how to acheive this:
http://salesforceapexcodecorner.blogspot.in/2011/06/image-as-commandbutton-on-visualforce.html
You have to use Javascript,
onclick String The JavaScript invoked if the onclick event occurs--that is, if the user clicks the image.
http://www.salesforce.com/us/developer/docs/pages/Content/pages_compref_image.htm
And get the parameters that you want.
Regards,
Ashish
<apex:image value="{!sLogo}" width="180" height="60"/>
<apex:param value="{!sLogo}" name="First"/>
</apex:commandLink >
In the controller you will get parameter
String param = Apexpages.currentPage().getParameters().get('First');
System.debug('printing value'+param );