If your using a Command Button to print the report then put it in the "click" event. It can be just about anywhere in your code. The DataEnvironment and DataReport are Public objects.