You need to sign in to do that
Don't have an account?
Ahmad Helal
Create a VF Page with a list of available Pick-list Values.
I have a custom object with a custom multi-pick-list field and would like create a VF page that displays all the different pick-list value options that users can just use to copy and paste.
Can someone help with the controller and VF page code?
Thanks.
Can someone help with the controller and VF page code?
Thanks.
Using the code that Ankit provided in the link you pasted, you'll use that in Visualforce controller (or extension). You'll want to add the picklist values to a List of strings (member variable that is in your controller).
In Visualforce, you'll use the apex:repeat tag to iterate over the list of strings and either use the apex:outputText tag or a merge field {!loopVar} to print the picklist values out.
You stated you wanted to learn more about this, so I would suggest checking out the Visualforce Basics trailhead module here: https://developer.salesforce.com/trailhead/module/visualforce_fundamentals
All Answers
It sounds like you're looking for someone to write the code for this project. These forums are not meant for that; you'll want to post over on the AppExchange site where you can match up with a developer looking to work on your project.
https://appexchange.salesforce.com/developers
I would actually like to learn how to do this. I don't have the resources to just hire a developer for every thing that comes up. If only I had that luxury, my world would be a lot less painful. I've done some simple apex and VF in the past, but don't develop on a regular basis.This seems pretty straight forward. Maybe someone can help point me in the direction, or another way to accomplish this.
I'm not trying to abuse the forum, but I've seen several cases where people ask a simple question and people will respond back with a full code snippet on how to accomplish it....
I ran across this:
https://developer.salesforce.com/forums/?id=906F00000008zdLIAQ ---- this is the code to get the values; but I want to expand on it and display them on a page so a user can just copy them all at once.
Thx
Using the code that Ankit provided in the link you pasted, you'll use that in Visualforce controller (or extension). You'll want to add the picklist values to a List of strings (member variable that is in your controller).
In Visualforce, you'll use the apex:repeat tag to iterate over the list of strings and either use the apex:outputText tag or a merge field {!loopVar} to print the picklist values out.
You stated you wanted to learn more about this, so I would suggest checking out the Visualforce Basics trailhead module here: https://developer.salesforce.com/trailhead/module/visualforce_fundamentals
In Visualforce, you'll use the apex:repeat tag to iterate over the list of strings and either use the apex:outputText tag or a merge field {!loopVar} to print the picklist values out.
Now that I have a high level understanding; I can research the "nitty gritty" on each step.
Ya; I've been meaning to do that trail --- I'm at that point now where I need to be more comfortable with basic development.
Thanks again for your help. =)