Operation Manual

OLE
Inserting OLE objects into reports
16
320 Crystal Reports User’s Guide
When you double-click a linked OLE object, the program opens the
object’s server application with the object displayed and ready for editing.
You cannot edit a linked object in place in Crystal Reports because you
are working on the original object. Since the object could be linked to
multiple documents, displaying the original in the server application limits
access to one editor at a time.
Inserting OLE objects into reports
There are several ways to insert OLE objects into an application.
The OLE Object choice on the Insert menu can be used to import an
existing object or create a new one. You can place either embedded or
linked objects using this method.
Paste Special on the Edit menu can be used to copy or cut the object
from an OLE server application and paste it in a report. If the object can
be pasted in multiple formats, you need to decide which format to use.
For example, when inserting text from a Microsoft Word document, you
can paste the text as Microsoft Word document text (which can be edited
in Word), or as a metafile, which is simply a non-editable picture of the
text. Use Paste Special to place either embedded or linked objects.
Note: When inserting selected information (portions of larger files), it is best
to use Copy and Paste Special editing. When inserting entire files, click OLE
Object from the Insert menu.
u
To copy and paste OLE objects
This procedure assumes that you have Microsoft Excel or another
spreadsheet program on your computer that is an OLE server application.
1. Open both Crystal Reports and Microsoft Excel.
2. Open an existing report in Crystal Reports.
3. Create a spreadsheet in Microsoft Excel by typing the numbers one
through ten (1-10) in cells A1 through A10.
4. Select cells A1 through A10, right-click and select Copy from the shortcut
menu in Excel.
5. Go to Crystal Reports and select Paste from the Edit menu.
6. Place the cells into the Details section of the report.
7. Right-click the spreadsheet object in the report and observe that it is
identified as an OLE object and that the third command from the last
identifies it as a Worksheet Object.