How to Delete or Deactivate Apex Class / Trigger in Salesforce Production Org

How do you delete or deactivate the Apex classes/triggers on your Salesforce Production Org? Unfortunately, it is not as simple as going to the Apex class and hitting the delete button or unchecking the 'Active' checkbox.

For deleting or disabling the code, you can take one of the following two routes:

1. Probably the simplest way to delete/disable is to connect to your Salesforce Production Org from VS Code, download the Apex class/trigger, change the status of the Apex class/trigger to "Deleted" or "Inactive" in the class/trigger XML file, and save. In this step-by-step guide, we are going to cover this method.

2. The second way is to use ANT Migration Tool, and here is the link to a knowledge article http://help.salesforce.com/apex/HTViewSolution?id=000006188&language=en_US on how to use this method.

(If you are not familiar with ANT Migration Tool, here is just the guide you need - #Step-by-Step Guide on Getting Started with Salesforce ANT Migration Tool)