If you click on a text box or a label with the right clicker and then click Properties and select Event tab you will see a whole range of Events such as OnClick, LostFocus. You attach code or macro on the Event you want. The little drop down arrow will list your macros or you can just type the macro name in. If you click where you see the 3 little dots then that brings up code builder and that is where code goes.
You can also make a button and use its Event property.
On the form itself if you right click on the area outside your form in design view and then Properties/Events that will show all the Events for the form itself. OnCurrent is a common one at runs the code or macro as you move to each record.
If you learn, like the back of your hand.....SetValue or = for code, open a form for specific record or records and be able to apply conditions you can make a very good data base and especially if you learn the IIF function and applying it in a query as well as various date functions. SetValue/= also allows you to change many field and form properties, a very common one being to make something visible or invisible. Virtually every thing you can do to a form in design view can also be done with SetValue/=
I think Access 2007 is different, I have never seen it, but a basic difference between code and macros is that code attached to an Event becomes part of the form, that is, if you exported the form to another data base or made a copy of the form then the code comes with it. Macros are "called" and are not part of the form(Access 2007 might be different)
Code can also be "called" when it is done as a Module. However, code allows more to be done than macros and code can also be used in a query.
Mike