Where in Salesforce to create a trigger
There are two ways to create a trigger in Salesforce page; Setup or Developer Console
In the setup, open the folder ‘App Setup’ -> Customize. Select the Salesforce standard component and click on the Triggers menu. Click on ‘New’ to create a trigger.
In the developer console, selects File -> New -> Apex Trigger
A dialog box appears for the trigger name and a list of Salesforce standard objects for the trigger to apply. Lets create a trigger, UpsertOpportunityTypeCheck, applying to Opportunity objects:
We can enter the Apex code to the main console screen and select ‘File -> Save’. This will send the code to the Salesforce cloud and compile the code. If any errors, this will appear in the ‘Problems’ tab. Once the trigger is compiled fine, we can see that trigger in ‘App Setup’ -> Develop -> Triggers. To modify the trigger name, simple change the name in the trigger code.