Copying Selected Data Between Applications

 < Day Day Up > 

In Chapter 17, "Exporting and Importing Data with Other File Formats," you learned to export and import Project data in other file formats, using Project's Open and Save commands. You learned to exchange whole projects and to use Import/Export maps to work with selected blocks of data. In this chapter, you will learn how to exchange individual field values as well as objects between files, using the Copy and Paste commands and the Insert Object command. Both data that you paste into Project and objects that you insert into Project can often be linked to the original source, to enable you to update the Project document to show the most current values in the source file.

NOTE

Unless you are very competent using VBA (Visual Basic for Applications) to write macros that send Project data to other applications, you will find that using Copy and Paste is the only easy way to copy Project's timephased data into other applications. Import/Export maps don't handle timephased data, and Project's timephased reports can only be sent to the printer or viewed onscreen in Project.


If you do not need to transfer all the information in a file (for example, you need just one or a few values from the source document), you can use the Windows Clipboard to copy and paste the data from one application's document (the source) to another application's document (the destination). Project can be the source or destination for exchanging data this way. You can simply paste a copy of the values or you can paste a permanent link that displays the current value from the source document but also can be updated on demand to display any changes in the source document.

When you are pasting Clipboard data into a table in Project, it is very important that you select the correct field(s) to receive the data. When you're importing files, the Import/Export map defines where the field data will be pasted. But with the copy and paste procedure, the paste location depends on where you click the mouse to make a selection just before you use the Paste command.

If you are pasting a single value, it's easy to select a recipient field that is appropriate for the value you are copying. If you are copying a block of two or more columns of values, however, you need to be in a table view in Project that has the appropriate columns next to each other to receive the block of copied values. Frequently, this means that you must define a custom table in Project to display the data field columns in the same order as the data that you are copying. When you paste the data into Project, you might also have to have a custom table displayed in the current view.

graphics/note_icon.jpg

If you change the columns in the standard table for the current view and then find that you don't want the changes in all views that use that table, see "Restoring Standard Tables That Have Been Customized" in the "Troubleshooting" section at the end of this chapter. Also see "Efficiently Customizing a Table" in the "Troubleshooting" section for steps for creating customized tables.


The Excel worksheet in Figure 18.1 is laid out with fields for the resource names and the cost rates for each resource. The standard Entry table in the Resource Sheet view does not match this layout; it has five other columns between the Resource Name and the Standard Rate columns. Therefore, you should create a custom Entry table and hide those five columns to allow the data to be pasted correctly (see Figure 18.2).

Figure 18.1. To correctly paste this spreadsheet data, you need to create a custom table in Project, with columns laid out in exactly the same order as in the spreadsheet.

graphics/18fig01.jpg

Figure 18.2. A custom resource table called Paste Entry can be created to accept the data pasted from the spreadsheet shown in Figure 18.1.

graphics/18fig02.jpg

You must also be sure that the cell you select before executing the Paste command is the cell that should receive the upper-left cell of the pasted block. In Figure 18.2, the cell containing Terry Uland was selected before pasting.

Copying Data from Other Applications into Project

To copy data from another application into Microsoft Project, follow these steps:

  1. Select the source data. You can select a single value or several values, as shown in Figure 18.1. If you select several values, be sure that the layout of the values matches the order of the values in the Microsoft Project table that will serve as the destination.

  2. graphics/copy_icon.gif

    Place the data on the Clipboard by choosing Edit, Copy; by pressing Ctrl+C; or by clicking the Copy button on the Standard toolbar.

  3. Activate Microsoft Project and select a view with a table that contains columns in the same order as the data you are copying, as shown in Figure 18.2.

  4. Select the task or resource row and the first field in the table that is to receive the data. If you select blank rows, Microsoft Project creates new tasks or resources with the data you copy. If you select rows that already contain data, Project replaces the existing data with the newly copied data.

    NOTE

    If you overwrite an existing resource, you are simply changing field values for that resource. Any tasks assigned to that resource are still assigned to iteven though the resource name may have been changed.

  5. graphics/paste_icon.gif

    Paste your data into the target application by choosing Edit, Paste; pressing Ctrl+V; or clicking the Paste button on the Standard toolbar.

The paste operation places a static copy of the current value from the source document in the field that you selected. Microsoft Project does not automatically update this value if the value in the source document is changed.

If you select a field that does not support the data type you are importing, you see a pasting error message like the one shown in Figure 18.3. For example, the data from Figure 18.1 contained the text value N/A in cell D5 (the third row of the selection), and in Figure 18.3, Project says that it was unclear what to do with that value in the Overtime Rate field. The error message points out that the error was detected in ID 3 in the Overtime Rate column. The error dialog box offers you these option buttons :

  • Yes If you want to continue pasting and continue receiving error messages, choose Yes. The mismatched value will be pasted into the cell, and Project will attempt to make sense of it.

  • No If you want to continue pasting but without having to deal with any more error messages, choose No.

  • Cancel If you want to stop the pasting operation, choose Cancel. Note that if you were pasting a block of values and several have already been pasted, canceling the paste operation would cause the pasted values to remain in the Project document, but no more values would be added.

Figure 18.3. The pasting error message tells you where the error occurred and gives you clues about the type of data that is expected.

graphics/18fig03.jpg

CAUTION

Pasting dates into the Start or Finish fields for tasks creates soft constraints for those tasks (Start No Earlier Than constraints in projects scheduled using a start date, and Finish No Later Than constraints in projects scheduled using a finish date). You can change the constraint on the Advanced tab of the Task Information dialog box.


For more information about removing constraints and the types of constraints, see "Working with Task Constraints," p. 201 .


Copying Microsoft Project Data into Other Applications

To copy data from Microsoft Project to another application, follow these steps:

  1. Select a view and apply a table that displays the data you want to copy to the other application.

  2. Select the source data. You can select a single value, several adjacent values, whole rows or columns, or all cells in the table:

    • To select entire rows, click the ID number for the row or rows.

    • To select entire columns, click the column headers.

    • To select all cells in the table, click the Select All button above the ID numbers and to the left of the other column headers.

  3. Place the data on the Clipboard by choosing Edit, Copy or by pressing Ctrl+C.

  4. Activate the other application and select the location where you want to paste the data.

  5. Choose Edit, Paste, or press Ctrl+V.

Figure 18.4 shows a block of data copied from the Resource Usage view into an Excel worksheet. Prior to the Copy operation, the Cost table in Project was modified to include the Assignment field. After the Paste operation in Excel, the user typed and formatted the heading at the top of each column in the worksheet. You can now do the final formatting on this worksheet by using the Assignment column to separate the rows that contain resource data from the rows that contain assignment data.

Figure 18.4. Three columns of data have been pasted from the Resource Usage view in Project, and the data is now ready for final formatting in Excel.

graphics/18fig04.jpg

NOTE

To copy and paste the information contained in the timephased grid of either the Task Usage or Resource Usage views, you must follow a series of three steps. First, select the desired information in the table, and then copy and paste it to the destination application. Second, select the desired data in the timephased grid, matching the data in the grid with the appropriate rows in the table. You can then copy this information and paste it to the target application. Finally, type the column headings for both the table information and the timephased data in the target application.


graphics/note_icon.jpg

If you want to keep your project's column headers when copying entire columns, see "Making Column Headers Appear When Pasting" in the "Troubleshooting" section at the end of this chapter.


 < Day Day Up > 


Special Edition Using Microsoft Office Project 2003
Special Edition Using Microsoft Office Project 2003
ISBN: 0789730723
EAN: 2147483647
Year: 2004
Pages: 283
Authors: Tim Pyron

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net