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
Priya_MarupudiPriya_Marupudi 

Cannot deploy code from Sandbox to server? Getting error page doesn't exist.

Hi all,

 

I am trying to deploy my code in Production. But I am stuck with something. I know the reason but I can't find a workaround for this. Problem is:

 

I have this line in test method " PageReference pageRef = Page.ListOfReports;" where I am referrening the page which is not in Prod.

I am using the page called ListOfReports and I want to deploy this class which refers to Page ListOfReports and throws error saying that "Page List of reports doesn't exist".

And when I tried to deploy Page first the class that I am using is referred in Listofreports page and it throws the same error that the class doesn't exist.

Can anyone help me with this please?

 

Thank you

-Priya.

 

sfdcfoxsfdcfox

You need to deploy the test class, page controller, and page all in a single changeset or package file. It sounds like you may have forgotten to include the page's controller or extensions, which caused the page to fail deployment, which caused the test class to fail.