This is my first time trying to code a trigger in Salesforce. I have a checkbox labeled "Priority Contact," and I'd like the checkbox to be checked for all contacts that have at least one Opportunity or Meeting event linked to them. Could you please advise on how I should go about doing this? I'm also not 100% sure where to enter the code to activate the trigger. Thank you.
If you're new to writing triggers, I'd recommend checking out SFDC99, which has some great tutorials on Apex for beginners. You'd want to write the code for your trigger in your sandbox, and then deploy it to your production instance once you have perfected the trigger and a test class for it.
To get started, log into your sandbox, go into Setup > Customize > Contacts > Triggers and hit new. That's where you'll enter the code! Then you'll also need to go into Setup > Deploy > Apex Classes > new to add a Test class, and run that to make sure your trigger passes the tests. Check out sfdc99.com and the developer guide.
If you want to update the field labeled "Priority Contact" on an DML event, then you can write a trigger for that. For this you can simply update the checkbox field of the current contact(trigger.new) and adding a check for eg contact.opportunity!=null. But if you want the checkbox to be checked for ALL contacts that have at least one Opportunity or Meeting event linked to them, then you can simply develop a script for that.
You can learn to write a simple trigger from here http://www.salesforcetutorial.com/apex-trigger-create-simple-trigger/