function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Aditya Rayavarapu 5Aditya Rayavarapu 5 

Passing data from one VF page to another

Hello,
 

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?
Thanks!

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

https://www.salesforce.com/us/developer/docs/pages/Content/pages_controller_readonly_context_pagelevel.htm

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

https://developer.salesforce.com/forums/ForumsMain?id=906F0000000AfapIAC

https://developer.salesforce.com/forums/ForumsMain?id=906F000000097HhIAI