Microsoft Visio Version 2002 Inside Out (Inside Out (Microsoft))

3 4

Just as there are many ways to display Visio information in other applications, there are several methods for bringing data in. Which method should you use?

Embedding and Linking Microsoft Office Documents in Visio

Earlier in the chapter, you learned how to use OLE to insert Visio diagrams into other documents. To insert other documents or objects into Visio diagrams, you use the same techniques.

If you add a link to another document from within a diagram, Visio stores a reference to that document file in the diagram, and it automatically updates the link every time you open the diagram. You can edit the original document either by double-clicking the linked file in the Visio diagram or by editing the original in its native application. Either way, both will be updated at the same time. Of course, you can only use the linked data if the other application is installed on your computer and if the linked file keeps the same name and remains in the same location.

If you embed a document in a Visio diagram, you don't need to worry about the location of the original, and you don't need to have the document's native application installed. If you do have access to the native application, though, you can edit the embedded object from within the Visio diagram. Double-clicking it will give you full editing capabilities. When you edit an embedded object, it has no effect on the original document. However, because the entire object is included in the drawing file, rather than just a reference, the drawing's file size will be much larger.

To link to a document in Visio, follow these steps:

  1. In Visio, choose Insert, Object.
  2. In the Insert Object dialog box, select the Create From File option button, and then locate the file to which you want to link.
  3. Select Link To File.
  4. Click OK to return to the Visio diagram.

To edit the object, double-click it to display the toolbars from its native application. When you're done editing the object, click anywhere in the drawing outside the object window; the Visio controls reappear.

To embed a document in Visio, follow these steps:

  1. In Visio, choose Insert, Object.
  2. In the Insert Object dialog box, select the Create From File option button, and then locate the file you want to link to.
  3. Click OK to return to the Visio diagram.

Tip


If you want to create a new document, select Create New instead, and then select the drawing type. A drawing window for the other application appears, where you can create your object.


Troubleshooting

An imported image doesn't appear correctly in an embedded diagram.

If you embed or export a Visio diagram that includes an inserted enhanced metafile picture, the image may appear as a crossed-out box. This happens when you save the Visio drawing file in Windows Metafile Format (WMF) or when you embed the Visio diagram into an application that supports only WMF files. You can safely embed enhanced metafiles (which Visio creates when you rotate a metafile) in applications that support this file format, including Visio and Microsoft Office. As long as you don't need to rotate the inserted picture, your Visio drawing file will be compatible with more applications if you import graphics as WMF files instead of picture (enhanced metafile) files.


Importing Graphics

You can import a picture or graphic file that was created in another application even if you don't have that application. For example, you can import a corporate logo that appears on the page with an organization chart. Visio can import most of the standard graphic file formats, so there's almost certainly a format that Visio and the graphics application have in common.

InsideOut


When you export a file from another application, the file's data is translated and saved to a separate file in a different format. When you import the file into a Visio drawing, the file is translated again. Because an image is changed slightly each time it`s translated, the picture you import into your Visio drawing might not look exactly the way it does in the original application.

There are two ways to import graphic files:

Files you open are larger than files you insert, so if you need to keep your drawing file small, insert the data.

Tip - Import ABC FlowCharter or CorelFlow! Files


If you're importing ABC FlowCharter or CorelFLOW! files, open the files (File, Open); don't use the Insert, Picture command, which converts the file contents to metafile images. Visio includes master shapes that match the images provided with ABC FlowCharter 2, 3, and 4[BG2] and many of the shapes provided with CorelFLOW! 2.0 files. When you open an ABC FlowCharter or CorelFLOW! file, Visio converts the images in the file to their equivalent Visio shapes.

To insert a picture or graphic file, choose Insert, Picture, From File. The Insert Picture dialog box can display small previews, or thumbnails, of your files' contents, as Figure 7-9 shows. To insert a file, double-click a thumbnail or file name. Depending on the format of the file, you might see another dialog box that includes importing options. Visio uses the same filters to open and insert pictures and graphic files, so the same dialog boxes appear for both procedures.

Figure 7-9.  The View Thumbnails option makes it easier to find the picture you want but slower to scroll through many picture files.

Tip


If you don't see the file you want to open, make sure the appropriate file type appears in the Files Of Type box.


Troubleshooting

Quality is poor with an imported graphic file.

There could be a couple of reasons for this, depending on the type of graphic you're importing. Try the following procedures:


When you import a graphic in a bit map format, it comes into your Visio drawing as a single picture that you can edit a little—you can resize it, move it around on the page, crop it, or move it to a different layer. Bit map graphics include files with the following extensions: .bmp, .dib, .gif, .jpg, .pct, .png, .tif, and .pcx.

Vector graphic formats, however, give you a little more control. Most vector graphics are converted to metafiles as they are imported. Visio can import the following vector formats: .af3, .af2 (ABC FlowCharter), .ai, .dwg, .dxf, .cgm, .cmx, .cdr, .cfl, .eps, .emf, .igs, .drw, .dsf, .ps, .txt, .csv, and .wmf. You can move a vector graphic around on the page, just as you can move a bit map picture. You may also be able to convert it to Visio shapes, which creates a new shape for every separate component that makes up the metafile. To do this, select the metafile, and then choose Shape, Grouping, Ungroup (or press Shift+Ctrl+U). You may need to do this more than once to ungroup everything.

Note


When you ungroup a metafile graphic, you might get dozens or hundreds of components. For example, you'll see all the paths or each band of a gradient fill. Additionally, text may appear as outlines.

Using Filter Options When Importing

The Filter Options dialog box gives you some control over the conversion of a picture or graphic file as Visio imports it. Most of the filters provide color translation options (which are the only options for bit map files). The color translation options are the same as those available in Visio export filters. Table 7-1 lists what each does. Filters for EPS, PCT, and some other vector formats include additional options that determine how the converted graphic appears, as Table 7-2 shows.

Table 7-1. Color Translation Options When Importing Bit Maps

Option Result

Normal

Visio attempts to match the colors of the original image.

Inverse

Visio reverses the colors of the image. Black becomes white, dark blue becomes light yellow, and so on.

Inverse Grays Only

Visio retains the image's original colors but reverses their black, gray, and white values so that dark blue becomes light blue, light red becomes dark red, and so on.

Gray Scale

Visio converts all colors of an object to their gray values.

Inverse Gray Scale

Visio applies both Gray Scale and Inverse options, as in a photographic negative.

Table 7-2. Color Translation Options When Importing Vector Formats

Option Result

Retain Gradients

Visio re-creates the gradients in the original image. If you don't select this option, Visio fills the object containing the gradient with the last color of the gradient.

Retain Background

Visio preserves the background color of the original image. To do this, Visio creates a background rectangle in that color and overlays the image.

Emulate Line Styles

Visio draws thick or patterned lines as polygons rather than as simple lines to ensure that they match the line styles of the original file.

Editing Imported Graphics

You can improve an imported picture's appearance by adjusting its contrast, brightness, and other values. Using the Picture command on the Format menu, you can work with color editing tools that might be familiar to you if you use other picture editing programs. As Figure 7-10 shows, you can adjust the levels of several properties and get immediate feedback—the preview shows the effect of an option. For example, if an imported picture looks dark on your computer screen, adjust the brightness (the gamma option). To make the edges in the picture stand out, increase the sharpness.

Figure 7-10.  Adjust contrast, brightness, midtones, and other options with the new Format Picture command.


Troubleshooting

An imported graphic cannot be edited in Visio as expected.

There are several possibilities when this occurs:


Inserting Pictures from a Scanner or Digital Camera

A new way to bring information into Visio is to insert it directly from your scanner or digital camera. If you have set up the hardware and installed the software for either a TWAIN-compliant or WIA-compliant digital camera or scanner, you can use it to insert pictures into Visio. Choose Insert, Picture, From Scanner Or Camera to display a dialog box with the options shown in Figure 7-11. Use the Web Quality or Print Quality option for quick results. These options specify default settings for images you'll display on the screen or Web (choose Web Quality) or use in a printed diagram (choose Print Quality). To adjust settings yourself, or if you're using a digital camera, click Custom Insert. Visio embeds the image as a picture that can't be edited.

InsideOut


A TWAIN or WIA interface allows a scanner or digital camera to be controlled by another program, such as Visio, so that the hardware device's output can be used directly by the program. TWAIN stands for Technology (or Tool) Without An Interesting Name—evidently, its inventors were stumped. WIA stands for Windows Image Acquisition and was originally developed for Microsoft Windows Millennium Edition (Windows Me).

Figure 7-11.  If a scanner or digital camera is installed on your computer, or if you have access to these devices over a network, you can bring pictures directly into Visio by choosing Insert, Picture, From Scanner Or Camera.

Tip


When you scan pictures, Visio adds them to the Microsoft Clip Organizer so that you can reuse them. To display the Clip Organizer, choose Insert, Picture, Clip Art. To prevent Visio from adding your scanned images, in the Insert Picture From Scanner Or Camera dialog box, clear the Add Pictures To Media Gallery option.


Troubleshooting

The Insert Picture From Scanner Or Camera command won't work.

Is your digital camera or scanner turned on and connected to the port where its card is installed? It's always wise to check connections. If that's not the problem, you can try some standard hardware and software diagnostics:


Other Methods for Using Data from Other Applications in Visio

While linking, embedding, and importing graphics are the most common methods for bringing pictures, text, and other data into Visio diagrams, there are a few other ways you can import information:

Категории