You need to sign in to do that
Don't have an account?
ishwarya ishu
when giving reason and status for the case object and saving it. this saved record should be displayed in another new VF page
after clicking save, the record should be displayed in new VF page. Anyone please send me a code
<apex:page standardController="Case" showHeader="false" > <apex:form > <apex:pageBlock title="Case Status"> <apex:pageBlockSection columns="1"> <apex:inputField value="{!Case.Status}"/> <apex:inputField value="{!Case.Reason}"/> <apex:inputField value="{!Case.Priority}"/> </apex:pageBlockSection> <apex:pageBlockButtons > <apex:commandButton action="{!save}" value="save"/> </apex:pageBlockButtons> </apex:pageBlock> </apex:form> </apex:page>
when giving reason and status for the case object and saving it. this saved record should be displayed in another new VF page
I believe your current code will redirect you to the newly created case record. If you would like to redirect to others page you might need to create a controller class. What is your new VF page?
It is saved in case object, but i need only this record should be displayed in a new page. i think this can be done using id. but i dont know .
Hi ishwarya ishu,
please try this for your need. Hope it will help you.
Vf Page 1
Vf Page 2
Apex controller
Mark as a best if it will help you.
Regards,
Suraj
Through Page Refernce you can Rediret to ur exiting vf page ,:
public PageReference redirect(){
PageReference pg=new pageReference('/apex/sample');
return pg;
}
here 'sample' is name of the vf page ,
this Redirect Method will be called from Redirect button on Vf page
<apex:commandButton value="redirect" action="{!redirect}"/>
thanks,
please mark it as a best answer if it solves the problem.