Define on OLE Object

Objects>>OLE

Lets you create an OLE object. An OLE object is an object from another Windows application such as a chart created in Microsoft Excel that you embed onto a DataEase document.

An OLE object lets you embed or copy (not link) an object from another Windows application such as a Bar, Pie, or 3D chart into a DataEase document using the Microsoft OLE (Object Linking and Embedding) protocol.

A document that contains an OLE object is called a compound document. When you embed an object created in another Windows application, the object is stored as part of the DataEase document.

 

Overview of OLE Concepts

Object

an entity that contains data from an external source application.

Client

the application that receives and stores an OLE object. DataEase is an OLE client (e.g., when you embed a Microsoft Excel chart in a DataEase form, DataEase is the client application).

Server

the application that remotely creates, updates, and displays an object. For example, when you embed a Microsoft Excel chart in a DataEase document, Excel is the server (or source) application. DataEase is not an OLE server.

Linking

inserting a link into a DataEase document. When you link an object, DataEase references the information stored by the server application.

Links are created using the Copy DDE Link button on the Create OLE Object dialog. Links are also created using the Paste Link and Paste Special options on the Edit menu.

Embedding

inserting a new or existing object into a DataEase document. When you embed an object, all the information normally stored by the server application is stored by DataEase.

Differences Between Linking and Embedding

The differences between linking and embedding an OLE object are summarized below:

 

How to Define an OLE Object

  1. Choose Objects>>OLE.

  2. DataEase displays the OLE cursor.

  3. Draw a rectangular OLE area in the Form object on the document.

  4. Click and drag the mouse on the document to mark the upper left and lower right corners of the OLE area. As you move the mouse, DataEase displays dashed lines that mark the OLE area border. When you release the mouse, DataEase displays the Insert OLE Object dialog.

  5. Choose which object class you want to create. Then, click on Linked or Embedded and click OK.

  6. DataEase opens the source application that contains the object type you selected.

  7. Create a new object. If you chose Linked on the Create OLE Object dialog, you can open an existing object.

  8. If you are creating a Linked object, choose File>>Save As from the source application's File menu. Then, press Alt+Tab one or more times to return to DataEase.

  9. If you are creating an Embedded object, choose File>>Update from the source application's File menu. Then, choose File>>Exit to return to DataEase.

  10. DataEase displays the OLE Paste Dialog. Click OK to paste the OLE object. DataEase displays the document and the Linked or Embedded object.

NOTE: When you access a source application from DataEase via OLE, the source application's File>>Save option is replaced by File>>Update if you are embedding the object.

 

The Create OLE Object Dialog

Object Class

tells DataEase what type (or class) of source object you want to link or embed in the current document. When you display the Create OLE Object dialog, DataEase lists all the OLE-aware applications available on your computer. A sample Object Class list is shown below. Choose:

Excel Chart - to link or embed a Microsoft Excel chart.

Excel Worksheet - to link or embed a spreadsheet created in Microsoft Excel.

Package - to embed a package. A package is a custom-defined OLE object that invokes another OLE object, executable program, and/or command line from within a DataEase document. A package is represented by an icon or graphic.

Paintbrush Picture - to link or embed a picture created in Microsoft Paintbrush.

Sound - to play a sound file (if your computer has a multimedia sound adapter card). For example, you can digitize a spoken help message or other sound effect for your document.

Linked

lets you insert an existing object (that references the information stored by the server application) into a DataEase document.

Copy DDE Link

opens the Paste Special dialog. The Paste Special dialog lets you paste data (not visible in Designer View) or a link to another Windows product in a DataEase document.

Embedded

lets you insert a new or existing object (that tells DataEase to store the information normally stored by the server application) into a DataEase document.

Adding Sound and Video to a DataEase Document

To enhance your application with multimedia, DataEase lets you add pre-recorded sound and video clips to any form, report, procedure, or menu document.

You can embed pre-recorded sound and video clips in two ways, by using either:

Embedding Mutimedia in a DataEase Document

You can easily enhance a document by adding a music, sound effect, or recorded speech sound clip saved as a waveform (.WAV) file, or by adding a full-motion video clip saved as an audio/video (.AVI) file.

Try recording a help message as a .WAV sound file instead of displaying a form or field help messages on the screen. Similarly, you can annotate a report to clarify the importance of the newly generated data.

System Requirements

To embed a sound (.WAV) file in a document using OLE, you must have Windows Sound Recorder or Media Player installed on your computer. To play a sound file, you must have a Windows-compatible sound card or a speaker driver such as Microsoft's SPEAKER.DRV file installed on your computer.

To embed an OLE video (.AVI) clip in a document, you must have both Video for Windows and Media Player installed on your computer.

See your Windows documentation for information on installing the Windows Sound Recorder and Media Player applications.

 

How to Play an Embedded Sound Clip in User View

To listen to a sound clip embedded in a DataEase document, double-click on the Sound Recorder microphone object. DataEase plays the .WAV file associated with the current record.

 

How to Play an Embedded Video Clip

  1. To play a video embedded in a DataEase document, double-click on video window. DataEase plays the .AVI file associated with the current record.

  2. Using OLE, you can embed a sound (.WAV) file in a DataEase document. The steps below describe how to add a help message to the ACTIVITIES form.

 

How to Add a Sound Clip to a Document

  1. Without exiting DataEase, switch to the Windows Program Manager by pressing the Alt+Tab one or more times.

  2. Start the Windows Sound Recorder application by double-clicking on the Sound Recorder icon (which should be located in the Accessories group).

  3. Sound Recorder opens.

  4. Choose File>>Open from the Sound Recorder File menu.

  5. Sound Recorder displays the Open dialog.

  6. Locate the C:\DFW\CLUB directory and highlight the ACTHELP.WAV file. Click OK to load the .WAV file.

  7. Choose Edit>>Copy to copy the .WAV file to the clipboard.

  8. Return to the DataEase ACTIVITIES form by pressing Alt+Tab one or more times.

  9. Switch to Designer View by clicking the Designer View button on the Toolbar.

  10. Choose Edit>>Paste to paste the sound file into the ACTIVITIES form.

  11. DataEase displays the hand pointer.

  12. Click and drag to position the sound object above the Activity picture.

  13. DataEase pastes the Sound Recorder microphone icon into the ACTIVITIES form to indicate the presence of an embedded sound file.

  14. Using OLE, you can embed a video (.AVI) file in a DataEase document. The steps below describe how to add a resort's promotional video to the CLUBS form.

 

How to Add a Video Clip to a Document

  1. Without exiting DataEase, switch to the Windows Program Manager by pressing the Alt+Tab one or more times.

  2. Start the Windows Media Player application by double-clicking on the Media Player icon (which should be located in the Accessories group).

  3. Media Player opens.

  4. Choose File>>Open from the Media Player File menu.

  5. Media Player displays the Open dialog.

  6. Locate the C:\DFW\CLUB directory and highlight the BORABORA.AVI file. Click OK to load the .AVI file.

  7. Choose Edit>>Copy Object to copy the .AVI file to the clipboard.

  8. Return to the DataEase CLUBS form by pressing Alt+Tab one or more times.

  9. Switch to Designer View by clicking the Designer View button on the Toolbar.

  10. Choose Edit>>Paste to paste the video file into the CLUBS form.

  11. DataEase displays the hand pointer.

  12. Click and drag to position the video object above the club name.

  13. DataEase pastes the video, paused at the first frame, into the CLUBS form, to indicate the presence of an embedded video file.