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
Mitch McConnellMitch McConnell 

Generating code from WSDL on a refreshed sandbox

I had generated code from my wsdl file, but subsequently refreshed my sandbox and 
lost it (!).  I have the original generated code.  My question is, can I simply bring over
that class as a new Apex class, or is there some reason I need to re-generated it
from scratch from the actual wsdl file on the refreshed sandbox?

Thanks,

mitch
 

James LoghryJames Loghry
Hi Mitch,

If I'm reading this correctly, it sounds like you need to reuse the WSDL2Apex function and regenerate the code from the WSDL since you lost it. Or did you have a backup of the class on your local drive or in source control you could refer to instead?  If you have a backup you can simply save it to the sandbox and it should be good to go.