Select View Code from the View - Events menu to display the Document Events window, which is used to enter code to change the default behavior of document-level events. Document-level events allow you to customize the behavior of open documents.