OLE

1:53 PM Posted In , , , , , , , , , , , , , Edit This 0 Comments »
Microsoft Windows includes a data transfer feature, Object Linking and Embedding (OLE). Microsoft touts OLE as a total data exchange solution.
Tip Pronounce OLE like the Spanish cheer, not the Cockney way of saying hole.
If you want to share data between two OLE-aware programs (such as most Windows applications), creating an embedded or linked document shouldn’t be much more complicated than cut and paste. That’s the theory.
Here’s how it works. In OLE lingo, the program that you’re taking the data from is the source. The program that receives the data is called the container. For example, if you want to place a spreadsheet table from Excel into an AutoCAD drawing, Excel is the source, and AutoCAD is the container.

Warning Why not just shout, “OLE!”?
Unfortunately, OLE is afflicted with practical problems.
Compound OLE documents can slow performance — a lot. If you experiment with OLE, you need a fast computer with lots of memory — or lots of time on your hands.
Supporting OLE well is a difficult programming job, and many applications — including AutoCAD — suffer from OLE design limitations and bugs.
Getting consistent hard-copy output can be tricky, especially when you plot from AutoCAD. OLE objects that look fine on-screen often undergo amazingly creative but not necessarily desirable transformations when they come out on paper.
The potential benefits of using OLE with AutoCAD just aren’t worth all the pitfalls and limitations. Use the alternative methods described in this chapter, and save OLE for your next trip to Spain.
In Excel, you select the range of spreadsheet cells that you want to put in the AutoCAD drawing and choose EditĂ°Copy to copy them to the Windows Clipboard. Then, you switch to AutoCAD and choose EditĂ°Paste Special. The Paste Special choice displays a dialog box containing the choices Paste and Paste Link. The Paste option creates a copy of the object from the source document and embeds the copied object into the container document. The Paste Link option links the new object in the container document to its source document so any changes to the source document are automatically reflected in the container document. In other words, if you link a spreadsheet object to an AutoCAD drawing, changes that you make later in the Excel spreadsheet get propagated to the AutoCAD drawing automatically. If you embed the same spreadsheet object in an AutoCAD drawing, changes that you later make to the data in Excel aren’t reflected in the AutoCAD drawing.
That’s how it’s supposed to work. In practice, the container application sometimes doesn’t display or print all of the linked or embedded data correctly. See the “Why not just shout, ‘OLE!’?” sidebar for details.

0 comments: