Skip to content. | Skip to navigation

Personal tools
Log in
Sections
You are here: Home Database Salesforce Apex & Visualforce Spontaneous Deactivation of Classes and Triggers

Spontaneous Deactivation of Classes and Triggers

If your Apex classes and triggers are all showing as "inactive" in production, here's how to fix it.
  1. Create a sandbox, but do not set it up in Eclipse
  2. For each Class and Trigger, click the Edit link and immediately click Save
    • This should make the class or trigger "Active" in the sandbox
  3. Create a project in Eclipse for your sandbox
  4. Deploy all Classes and Triggers from the sandbox to production
  5. NOTE: If you create the Eclipse sandbox project BEFORE you make the classes and triggers active, be sure to do a refresh of the sandbox Eclipse project after you've activated the classes & triggers and before you deploy!!

Troubleshooting Tips:
1. If your tests fail in the sandbox:
  • Make sure you've configured an Organizational Level custom setting for the Template and Trigger settings.
  • Make sure you've added the correct Individual Account ID to the right place in the custom settings.
2. If your tests pass in sandbox, but you get errors when deploying to production:
    • Make sure you've added the correct Individual Account Id to the right place in the custom settings in production.
    • Make sure the individual account is active in production (for some reason the "inactive" checkbox seems to get checked on DOT installation.)
    • Check the trigger metadata in your sandbox to make sure the triggers are, indeed, active (see NOTE in #5 above.)

 

If all goes well, production should now be good to go.

Document Actions

Comments (0)

« February 2012 »
February
MoTuWeThFrSaSu
12345
6789101112
13141516171819
20212223242526
272829