+ Start a Discussion
Aditya Rayavarapu 5Aditya Rayavarapu 5 

Passing data from one VF page to another


I have 2 VF pages to use for Web to Case.
On the first page, the user enters their name, email, problem, and uploads an image.

Then they click 'Review Data', which then takes them to the 2nd VF page called 'Summary'.
On this page, the user should be able to see their info (name, email, problem), without being able to edit it.

For the 'Review Data' button on the first page, I used 

public PageReference openSecondPage(){
    return Page.Summary.setRedirect(false);

Could anyone help me with displaying the user info as output fields on the second page?

Best Answer chosen by Aditya Rayavarapu 5
RamuRamu (Salesforce Developers) 
To do this, you would need to first pass the values from page 1 to controller and then use the same controller on the second page by setting the property as readonly. The below article has an example of this


Review the examples outlined in the below posts to pass values from one page to another.