Create a Query That Returns the Items in the Order

31-10 Oracle Reports Users Guide to Building Reports Figure 31–9 Data Link between two queries

7. Save your report.

31.5 Import a Check Image and Arrange Fields for Printing

The steps in this section will show you how to adjust the margins of your check printing report and align the fields with an image of a check. You can scan any check and use its image to lay out the objects of your check report. In this section, we use the image we have provided to you, called blankcheck.jpg. This image is located in the spellcash example folder.

31.5.1 Rearrange the layout objects

Before you can insert the check image, you must first rearrange the layout objects. To rearrange the layout objects: 1. Click the Paper Layout button in the toolbar to display the Paper Layout view. The layout currently looks like this: Figure 31–10 Paper Layout view of your report

2. Click the Edit Margin button in the toolbar.

3. In the Paper Layout view, click the margin frame the heavy black line to select it.

4. At the top of the frame, click the center black resizing square and drag it up, so

that the margin is 0.25 inches 0.5 centimeters. When you are done, it should look something like this: Tip: When you click the center square, notice that a dotted guideline displays while your mouse button is depressed. You can use these guidelines to help place objects exactly where you want them in the Paper Layout view. Building a Check Printing Report with Spelled-Out Cash Amounts 31-11 Figure 31–11 Paper Layout view with resized margin 5. Save your report.

31.5.2 Import the blank check image

In this section, you will import an image of a blank check. You can use any check you like. For this example, we have provided an image called blankcheck.jpg in the spellcash example directory. To import the blank check image:

1. While the frame is still selected, choose Insert Image.

2. In the Import Image dialog box, make sure that File is selected.

3. In the text box next to File, type or browse for the location of the image,

blankcheck.jpg, then click OK to display the blank check image in the Paper Layout view.

4. Click the Edit Margin button in the toolbar to return to edit mode. Notice that the

image no longer displays.

31.5.3 Set up the check printing fields

The steps in this section will show you how to use the various tools in the Paper Layout view to modify the look and feel of your check report. Here, you will learn how to add and modify layout objects and fields according to how you want them to display on the resulting checks. You will create copies of certain fields that you will then use in Section 31.6, Create a Check Stub With Payment Information and Order Details to create the check stub. To set up the check printing fields:

1. In the Paper Layout view, click the Order No. boilerplate text.

2. Click the Select Parent Frame button in the toolbar. The repeating frame called R_G_ORDER_ID should now be selected in the Paper Layout view. You can also look in the Object Navigator, under Paper Layout, to make sure R_G_ORDER_ID is selected. 3. While R_G_ORDER_ID is selected, click and drag the bottom center resize handle to 8.75 inches 22 centimeters, or the bottom of the page. 4. Click the Flex Off button in the toolbar to set Flex mode off. 5. In the Paper Layout view, click F_ORDER_TOTAL, then press CTRL+C on your keyboard. Tip: When you click and drag a resize handle in the Paper Layout view, guidelines display along the ruler to help you place your objects. In this case, drag the bottom center resize handle down the page until the horizontal guideline reaches 8.75 inches 22 centimeters. 31-12 Oracle Reports Users Guide to Building Reports 6. Click in the area below your layout objects and press CTRL+V. You should see a new field called F_ORDER_TOTAL1. If this field displays on top of the other layout objects, click and drag it down below the other layout objects so that your Paper Layout view now looks something like this: Figure 31–12 Partial Paper Layout view with F_ORDER_TOTAL1

7. Copy the F_ORDER_DATE field and paste it below the other fields, so that your

layout now looks like this: Figure 31–13 Partial Paper Layout view with F_ORDER_DATE1

8. Copy F_CUSTOMER_NAME and paste the field below the other layout objects,

so that your layout looks like this: Figure 31–14 Partial Paper Layout view with F_CUSTOMER_NAME1 9. Make two copies of F_CHECK_NO by pressing CTRL+C on your keyboard once, then CTRL+V twice. Note: When you copy and paste a field, Reports Builder maintains the size of the field. So, when you copy and paste F_ORDER_ DATE, you may not see the full name of the field. While the field is selected, you can click and drag the right border of the field to the right so that you can see the full name of the field, F_ORDER_ DATE1.