Excel2007 Advanced

Embed Size (px)

Citation preview

  • 8/9/2019 Excel2007 Advanced

    1/108

    Desktop Mentor

    Excel 2007

    Advanced

  • 8/9/2019 Excel2007 Advanced

    2/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 1 of 107

    Table of Contents

    Importing Data from Access ................................................................................................................ 4 

    Importing Data into an Existing Workbook ....................................................................................... 4 

    Opening Access Databases ............................................................................................................. 6 

    Importing Data from the Web ............................................................................................................... 6 

    Importing Web Data .......................................................................................................................... 6 Saving a Web Query ........................................................................................................................ 7 

    Importing Text Files .............................................................................................................................. 9 

    Importing from Other Data Sources .................................................................................................. 10 

    Importing Data ................................................................................................................................ 10 

    Viewing Existing Connections ........................................................................................................ 12 

    Sorting Data ......................................................................................................................................... 13 

    Sorting Data .................................................................................................................................... 13 Sorting by Colour ............................................................................................................................ 15 Sorting on Multiple Fields ............................................................................................................... 15

     

    Filtering Data ....................................................................................................................................... 16 

     AutoFilter ........................................................................................................................................ 16 Text AutoFilter ................................................................................................................................ 17

     

    Number AutoFilter .......................................................................................................................... 18 Top 10 AutoFilter ........................................................................................................................... 19 

     Advanced Filter ............................................................................................................................... 20 

    Adding Subtotals ................................................................................................................................ 21 

    Grouping and Ungrouping Data ........................................................................................................ 23 

    Creating Pivot Tables ......................................................................................................................... 24 

    Creating a PivotTable ..................................................................................................................... 24 Hiding Entries ................................................................................................................................. 26 Drilling Down ................................................................................................................................... 27 Table Options ................................................................................................................................. 27

     

    PivotTable Formatting .................................................................................................................... 29 

    Creating Pivot Charts ......................................................................................................................... 30 

    Creating a PivotChart ..................................................................................................................... 30 

    Hiding Entries ................................................................................................................................. 32 

    Freezing Panes .................................................................................................................................... 32 

    Database Functions ............................................................................................................................ 33 

    The Names Manager ........................................................................................................................... 35 

    Displaying the Name Manager ....................................................................................................... 35  Adding Range Names .................................................................................................................... 35

     

    Removing Range Names ............................................................................................................... 36  Amending Range Names ............................................................................................................... 36 

    The Scenario Manager ........................................................................................................................ 37 

    Creating Scenarios ......................................................................................................................... 37 Displaying Scenarios ...................................................................................................................... 39 Summary Reports ........................................................................................................................... 39

     

    Goal Seek ............................................................................................................................................. 40 

    Using the Goal Seeker ................................................................................................................... 40 

  • 8/9/2019 Excel2007 Advanced

    3/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 2 of 107

    Data Tables .......................................................................................................................................... 41 

    One Way Data Tables .................................................................................................................... 41 Two Way Data Tables .................................................................................................................... 42 

    Creating If Statements ........................................................................................................................ 44 

    Basic If Statements ......................................................................................................................... 44 

    If Statements with Multiple Conditions ........................................................................................... 45 Nested If Statements ...................................................................................................................... 46

     

    Creating Lookup Statements ............................................................................................................. 46 

    VLOOKUP Functions ...................................................................................................................... 46 HLOOKUP Functions ..................................................................................................................... 47

     

    Error Trapping ..................................................................................................................................... 48 

    Excel Error Messages .................................................................................................................... 49 

    Date and Text Functions .................................................................................................................... 49 

    Date Functions................................................................................................................................ 49 

    Text Functions ................................................................................................................................ 50 

    Auditing Workbooks ........................................................................................................................... 51 

    The Watch Window ............................................................................................................................. 52 

    Accessing Add-Ins .............................................................................................................................. 53 

    Calculation Options ............................................................................................................................ 55 

    Linking Formulas ................................................................................................................................ 56 

    Linking Formulas ............................................................................................................................ 56 

    Paste Link ....................................................................................................................................... 56 

    Maintaining Links ............................................................................................................................ 58 

    Adding Comments .............................................................................................................................. 59 

    Setting your User Name ................................................................................................................. 59 

     Adding Comments .......................................................................................................................... 59 Viewing Comments ......................................................................................................................... 60

     

    Editing and Removing Comments .................................................................................................. 61 Printing Comments ......................................................................................................................... 61 

    Sharing a Workbook ........................................................................................................................... 62 

    Opening Workbooks Already in Use............................................................................................... 62 Sharing Workbooks ........................................................................................................................ 63 Sharing Conflicts............................................................................................................................. 64 

    Tracking Changes ............................................................................................................................... 65 

    Accepting and Rejecting Changes .................................................................................................... 66 

    Inspecting Workbooks ........................................................................................................................ 67 

    Restricting Permissions ..................................................................................................................... 69 

    Restricting Permission in a Workbook ............................................................................................ 69 Opening a Workbook with Restricted Permission .......................................................................... 71

     

    Protecting Worksheets ....................................................................................................................... 72 

    Unlocking Cells for Editing .............................................................................................................. 73 

    Unprotecting Worksheets ............................................................................................................... 74 

    Protecting Workbooks ........................................................................................................................ 75 

    Creating a Document Workspace ...................................................................................................... 76 

    Saving to a Document Workspace .................................................................................................... 78 

    Data Consolidation ............................................................................................................................. 79 

  • 8/9/2019 Excel2007 Advanced

    4/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 3 of 107

    Data Validation .................................................................................................................................... 81 

    Setting Validation ............................................................................................................................ 81 Error Messages .............................................................................................................................. 82

     

    Showing Invalid Data ...................................................................................................................... 84 

    Saving in HTML Format ...................................................................................................................... 85 

    Creating Themes ................................................................................................................................. 87 

    Applying Saved Themes..................................................................................................................... 90 

    Customising the Quick Access Toolbar ........................................................................................... 91 

    Recording Macros ............................................................................................................................... 92 

    Showing the Developer Ribbon ...................................................................................................... 92 

    Recording Macros........................................................................................................................... 93 

    Relative Recording .............................................................................................................................. 94 

    Running Macros .................................................................................................................................. 95 

    Assigning Macros to the Quick Access Bar..................................................................................... 96 

    Assigning Macros to the Keyboard ................................................................................................... 97 

    Creating Forms .................................................................................................................................... 99 

    Setting Form Control Properties ..................................................................................................... 100 

    Linking Forms to Cells .................................................................................................................. 100 

    Setting List Values ........................................................................................................................ 101  Adding Formulas to Show Form Results ...................................................................................... 102 

    Saving Templates .............................................................................................................................. 102 

    Creating Templates ...................................................................................................................... 103 Using Templates ........................................................................................................................... 103 

    Creating Default Templates .......................................................................................................... 104 

    Macro Security .................................................................................................................................. 105 

    Assigning Macros to Buttons and Images ..................................................................................... 106 

     Assigning Macros to Buttons ........................................................................................................ 106  Assigning Macros to Other Objects .............................................................................................. 107 

  • 8/9/2019 Excel2007 Advanced

    5/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 4 of 107

    Importing Data from Access

    Importing Data into an Existing Workbook

    If the data you wish to use exists in an Access database, it can be imported into Excel as follows:

      Click in the first cell you wish to populate with the imported data

      Click on the Data ribbon

      Click on the From Access option in the Get External group

      Locate the folder that contains the database you wish to open

      Select the file you wish to open

      Click on Open 

    If your database contains more than one object (table or query), you will be given a choice of the object to

    open. Choose the object and click on OK.

  • 8/9/2019 Excel2007 Advanced

    6/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 5 of 107

    The Import Data window will display. Click on OK to insert the data as a table in the selected cell.

    If you wish to only import specific data from the database:

      Click on the Properties button in the Import Data window

      Click on the Definition tab

      Click on the drop-down arrow of the Command Type box and choose SQL 

      In the Command Text box, type the SQL string for the data you wish to import. For example, toimport all data from the Hotels table that has a rating higher than 2:

      Click on OK 

      Click on OK again to import the data

  • 8/9/2019 Excel2007 Advanced

    7/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 6 of 107

    If the Access database changes, you can update the workbook by clicking on the Refresh All button on the

    Data ribbon.

    Opening Access Databases

    You can also import an Access database by opening the file directly:

      Click on the Office button and choose Open 

      Click on the drop-down arrow of the file type list and choose Access Databases

      Locate the folder that contains the database you wish to open

      Select the file you wish to open

      Click on Open 

    If prompted, click on the Enable button to enable the data connection:

    If your database contains more than one object (table or query), you will be given a choice of the object to

    open. Choose the object and click on OK.

    Importing Data from the Web

    Importing Web Data

    You can import data directly from any page on the Internet or your company intranet. Web queriescan be saved and run in as many worksheets as necessary, and can be refreshed to show the latestfigures quickly and easily.

      Click in the first cell you wish to populate with the imported data

      Click on the Data ribbon

      Click on the From Web option in the Get External group

  • 8/9/2019 Excel2007 Advanced

    8/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 7 of 107

      Your browser home page will be shown by default. Locate the page containing the data you wishto import, by typing the URL in the Address box and clicking on Go 

      On the web page, locate the table you wish to import

      Click on the yellow arrow next to the table you want to import - you can select as many tables asrequired

      Click on Import

    The Import Data window will display. Click on OK to insert the data as a table in the selected cell.

    To update the data in a web query, click on the Refresh All button on the Data ribbon.

    Saving a Web Query

    You can save a web query, to allow you to import the data into another worksheet quickly and easily.

  • 8/9/2019 Excel2007 Advanced

    9/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 8 of 107

      Click in the first cell you wish to populate with the imported data

      Click on the Data ribbon

      Click on the From Web option in the Get External group

      Locate the page containing the data you wish to import, by typing the URL in the Address box

    and clicking on Go   Click on the yellow arrow next to the table you want to import - you can select as many tables as

    required

      Click on the Save Query button along the top of the Web Query window

      Type a name for the query, then click on Save 

    Web queries are saved with the .IQY file extension.

    To re-use a saved web query:

      Click on the Office button and choose Open 

      Click on the drop-down arrow of the file type list and choose Access Databases

      Locate the folder that contains the web query - by default this will be under your name thenAppData\Roaming\Microsoft\Queries 

      Select the file you wish to open

      Click on Open 

    If prompted, click on the Enable button to enable the data connection:

  • 8/9/2019 Excel2007 Advanced

    10/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 9 of 107

    Importing Text Files

    To import a text file into an existing workbook:

      Click in the first cell you wish to populate with the imported data

      Click on the Data ribbon

      Click on the From Text option in the Get External group

      Locate the folder that contains the text file you wish to open

      Select the file you wish to open

      Click on Import 

      The Text Import Wizard will be displayed. This helps you to arrange the data into appropriatecolumns, rather than all data appearing in a single column separated by commas.

      Choose Delimited if the columns should be separated at a set symbol e.g. a comma or tab

      Click on Next 

      Choose the delimiter character e.g. Comma

      Ensure the sample displays correctly and click on Finish 

  • 8/9/2019 Excel2007 Advanced

    11/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 10 of 107

      You can also open a text file directly by clicking on the Office button and the Open commands.Choose to show Text Files then locate the file you wish to open.

    Importing from Other Data Sources

    Importing Data

    If your data comes from a source other than Access, the Internet or a text file, you may be able to import

    the data using the From Other Sources option.

      Click in the first cell you wish to populate with the imported data

      Click on the Data ribbon

      Click on the From Other Sources option in the Get External group

      Choose From Data Connection Wizard from the drop-down menu

  • 8/9/2019 Excel2007 Advanced

    12/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 11 of 107

      Choose the kind of data connection you wish to make, then click on Next 

      Choose the file or server that contains the data you wish to import, then click on Next 

      If prompted, choose the table or object you wish to import, then click on Next 

      In the final step of the wizard, enter a file name for the connection, as well as a Friendly Name that can be used to identify the connection again at a later stage

      Click on Finish when the data wizard is complete

  • 8/9/2019 Excel2007 Advanced

    13/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 12 of 107

    The Import Data window will display. Click on OK to insert the data as a table in the selected cell.

    Viewing Existing Connections

    To view all of the external data connections in the current workbook, click on the Existing Connections 

    button on the Data ribbon.

     All connections will be listed:

  • 8/9/2019 Excel2007 Advanced

    14/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 13 of 107

      Open a previously used connection by clicking on the name in the Connection Files on thisComputer  list and clicking on Open 

      Edit a connection already in the workbook by right-clicking on the name in the Connections inthis Workbook list and choosing Edit Connection Properties

    Sorting Data

    Sorting Data

    It is not necessary to select the entire table before sorting it.

      Click anywhere within the column to be sorted

      On the Home ribbon, click on the Sort and Filter  button in the Editing group

    The menu options will differ depending on the type of data your column contains:

  • 8/9/2019 Excel2007 Advanced

    15/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 14 of 107

      If sorting a column containing text, choose Sort A-Z or Sort Z-A as required

      If sorting a column containing values, choose Sort Smallest to Largest or Sort Largest toSmallest as required

      If sorting a column containing dates, choose Sort Oldest to Newest or Sort Newest to Oldest asrequired

    The field names will remain at the top of the list and all records will be sorted in order of the column

    containing the active cell.

    Note: Even if you select a specific range in the table, all rows will be sorted when you choose the Sort 

    command.

    You can also sort the table by clicking on the drop-down arrow next to the heading of the column you wish

    to sort, then choosing the required sort option from the top of the menu:

  • 8/9/2019 Excel2007 Advanced

    16/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 15 of 107

    Sorting by Colour

    You can also sort a table by colour, so that cells with a specific text or fill colour will appear together at the

    top of the table.

      Click anywhere within the column to be sorted

      On the Home ribbon, click on the Sort and Filter  button in the Editing group

      Choose Sort by Colour  

      Choose the Fill or Text colour to move to the top of the table

    Sorting on Multiple Fields

    The sort buttons can also be used to sort in order of more than one field. For example, to sort the following

    list in descending order of Airport, with the same airports grouped in descending order of Price:

      First click anywhere in the Airport column and use the Sort Z-A command

      Next, click in the Price column and use the Sort Largest to Smallest command

  • 8/9/2019 Excel2007 Advanced

    17/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 16 of 107

    You can also use the Sort button on the Data ribbon to sort by multiple levels:

      Click on the drop-down arrow of the Sort By field and choose the first field to sort by

      Change the Order  if required

      Click on the Add Level button

      Click on the drop-down arrow of the Then By field and choose the second field to sort by

       Again, change the Order if required

      Repeat the above 3 steps for each level you wish to add

      Click on OK to sort the data

    Filtering DataAutoFilter

    To use AutoFilter:

      If the list does not show arrows next to each heading, turn AutoFilter on by clicking on the Data ribbon, then on the Filter  button in the Sort & Filter  group

      Click on the drop-down arrow in the heading of the column you wish to filter

       A list will display all values currently in the column - uncheck all values you want to hide from thelist

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    18/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 17 of 107

    To re-display all data:

      Click on the same drop-down arrow and choose (Select All) 

      Click on OK to show all data

    Text AutoFilter

    If the column you are filtering contains text, you can use the Text Filters option to apply custom filtering to

    the list. Custom filters allow you set specific criteria to be matched e.g. all entries containing a specific

    word, or all entries that end in specific characters.

      Click on the drop-down arrow in the heading of the column you wish to filter

      Click on Text Filters 

      Choose the type of comparison you wish to make e.g. Contains or Ends With 

  • 8/9/2019 Excel2007 Advanced

    19/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 18 of 107

      Click in the empty box in the top right of the dialog box and enter the text you wish to match

      To add a further condition, click on And if both conditions must be met, or click on Or  if eithercondition can be met

      Click on the drop-down arrow in the second line and choose the next comparison you wish tomake

      Click in the box next to this and enter the text you wish to match

      Click on OK when complete

    For example: The following would show all records that had the word "London" in this field, but only if they

    also started with "North".

    Number AutoFilter

    If the column you are filtering contains values, you can use the Number Filters option to apply custom

    filtering to the list e.g. to find all entries greater than 100, or between 50 and 75.

      Click on the drop-down arrow in the heading of the column you wish to filter

      Click on Number Filters 

  • 8/9/2019 Excel2007 Advanced

    20/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 19 of 107

      Choose the type of comparison you wish to make e.g. Greater Than or Between 

      Click in the empty box in the top right of the dialog box and enter the value you wish to match

      To add a further condition, click on And if both conditions must be met, or click on Or  if eithercondition can be met

      Click on the drop-down arrow in the second line and choose the next comparison you wish tomake

      Click in the box next to this and enter the value you wish to match

      Click on OK when complete

    Top 10 AutoFilter

    The Top 10 option allows you to choose the top or bottom number of records in a field - you could use it to

    find the top 10 sales or the bottom 5% of salaries.

      In the first box, choose whether to show the top or bottom items from the list

      Choose the number of items to display

      Choose whether to show the specific number of Items or the specified Percent 

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    21/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 20 of 107

    The Above Average and Below Average commands require no further input. These will work out the

    average value in the column, then show all records that have a value above or below this.

    Advanced Filter

     Advanced filtering is used with more complex criteria or if you wish to copy the filtered list to another

    location in the workbook. There are three ranges that are needed to perform an Advanced Filter:

    Range Description

    List Range This is the entire data list that you wish to filter - all matching records will befound in this range

    Criteria Range This is the area of the worksheet in which you specify what data you want tofind in the data list e.g. all clients in London or all accounts with a balanceexceeding £1000.

    Copy To Range All records of the database range that match the specified criteria will be copied

    here

    Before filtering the list, set up the Criteria range. This should contain the relevant column headings in the

    first row and the criteria itself on the following lines. Multiple lines of criteria can be entered, but care should

    be taken that conditions are placed on the correct line:

      If both conditions must be met, these should be placed on the same line. The following criteria willonly show Excel courses if they had a level of Advanced:

      If either condition can be met they should be placed on separate lines. The following criteria willfind all Excel courses, regardless of their level, as well as all Advanced courses, regardless oftheir subject:

    To filter the list:

      Click anywhere in the list you wish to filter

      On the Data ribbon, click on the Advanced button in the Sort & Filter  group

      Choose to Copy to another location 

  • 8/9/2019 Excel2007 Advanced

    22/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 21 of 107

      Click in the Criteria box, then select the range you have set your criteria in, including the fieldnames

      Click in the Copy To box, then click on the cell you wish the matching data to be extracted to

      Click on OK 

    To filter records to a different worksheet, click on the cell you wish to filter to, then click on the Advanced 

    button on the Data ribbon. Choose Copy to Another Location, then enter the data list and criteria ranges.

    Enter the cell on the current sheet you wish to filter to, then click on OK.

    Adding Subtotals

    This feature automatically calculates totals in the specified column. If the data is sorted correctly,subtotals will be given for each group of records, with a grand total at the end.

      Sort the data list in the required order and click anywhere in the list

      Click on the Data ribbon

      Click on the Subtotal button in the Outline group

      In the At each change in box, specify the field to be grouped for subtotals  In the Use Function box, choose the function you want to use the summarise the data in each

    group

      In the Add subtotal to list, check each numeric field that you wish to show a total for

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    23/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 22 of 107

     An outline is created automatically.

      Click on level 1 to display the grand total only

      Click on level 2 to display sub totals and the grand total

      Click on level 3 to display all data and totals

      Click on the - symbol next to a group to collapse that group, showing on its total

      Click on the + symbol next to a hidden group to show all data again

      To remove subtotals from a list, click on the Subtotals button on the Data ribbon, then onRemove All.

  • 8/9/2019 Excel2007 Advanced

    24/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 23 of 107

    Grouping and Ungrouping Data

    You can group and ungroup data in a list to create an outline.

    Grouping will read the summary columns and rows in the worksheet i.e. those containing totals, andplace these into the highest level of the outline. Detail columns and rows i.e. those containing thenumbers to be summed, are placed into the lowest level.

    There can be up to 8 levels in an outline.

      Create the worksheet in the normal way, ensuring all formula are entered correctly and eitherbelow or to the right of the detail

      Click on the Data ribbon

      Create an outline by clicking on the Group button in the Outline group

      Choose Auto Outline

    In the following example, rows 5 and 10 contain subtotals, with row 12 containing the sum of thesesub totals. Column E contains a total for each row. When an Auto Outline is applied, these totals areput into levels as follows:

     An outline is created automatically.

      Click on a level number to hide all data to that level for a column or row

      Click on the - symbol next to a group to collapse that group, showing on its total

      Click on the + symbol next to a hidden group to show all data again

      To remove the outline:

      Click on the Data ribbon

  • 8/9/2019 Excel2007 Advanced

    25/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 24 of 107

      Create an outline by clicking on the Ungroup button in the Outline group

      Choose Clear Outline

    Press [Ctrl 8] to hide or display the outline symbols quickly.

    Creating Pivot Tables

     A PivotTable is a table used to summarise and analyse data from an existing list or worksheet. APivotTable is made up of row headings, column headings and intersecting summary data.

    This data list:

    Could be used to produce this PivotTable:

    Creating a PivotTable

    To create a PivotTable from a data list or table of information:

      Click on any cell of the list or table

      Click on the Insert ribbon

      Click on the PivotTable button in the Tables group

  • 8/9/2019 Excel2007 Advanced

    26/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 25 of 107

      Ensure the data list range is correct

      Choose the location for the PivotTable. Choose New Worksheet to place the PivotTable on a newworksheet in the current book or Existing Worksheet to place the PivotTable on an existing sheet

      Click on OK 

     A blank PivotTable is created in the location specified, with a task bar on the right-hand side where the

    PivotTable is built:

    To add a field to the PivotTable, drag the field from the field list to the relevant area of the task pane.

      Choose the field you wish to summarise by column, and drag this to the Column Labels box

      Choose the field you wish to summarise by row and drag this to the Row Labels box

      Choose the field that contains the values you wish to summarise for each column and rowheading and drag this to the Values box

  • 8/9/2019 Excel2007 Advanced

    27/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 26 of 107

     As you add fields to the task pane, the PivotTable will build automatically on the worksheet.

    Hiding Entries

    The PivotTable need not include all data from the underlying list - it is possible to hide specific categories or

    entries.

      Click on the drop-down arrow of the field used to summarise by row or column - all entries in thatfield will be displayed

      Click on the check box of each item you wish to exclude

      Click on OK when complete

  • 8/9/2019 Excel2007 Advanced

    28/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 27 of 107

    Drilling Down

    Drill Down allows you to double click on any of the summary figures of a PivotTable to view the details that

    make up this figure. Double clicking on a sum, for example, would show all figures (and the records) that

    make up the sum.

      Double click on the figure you wish to view the detail of

       A new sheet will be created containing the records

    For example, double-clicking on the Heathrow total in the example given at the top of this page would show

    the following detail sheet:

    The sheet can be deleted if no longer required. Right-click over the sheet tab and choose Delete from the

    shortcut menu to do this.

    Table Options

    To change the function used to summarise the table:

      Click on any value in the PivotTable

      Click on the Design ribbon

      Click on the Field Settings button in the Active Field group

      Choose the function you wish to use to summarise the data

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    29/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 28 of 107

     Additional PivotTable options can be set as follows:

      Click on the Options button in the PivotTable group of the Design ribbon

      To enter a default value into empty cells, or cells containing errors, enter the appropriate values inthe Format boxes

  • 8/9/2019 Excel2007 Advanced

    30/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 29 of 107

      Click on the Totals & Filters tab and choose whether to show grand totals for columns and/orrows

      Click on the Data tab and choose whether to refresh the PivotTable automatically each time it'sopened

      Click on OK when all options have been set

    If the original data in the worksheet is changed, the PivotTable will NOT automatically update. To update the

    PivotTable, select any cell in the table and click in the Refresh button on the Options ribbon.

    PivotTable Formatting

    The Layout ribbon can be used to format the PivotTable once it's been created.

      Click on the Layout ribbon

      Click on the drop-down arrow of the PivotTable Styles list

      Choose the style you wish to apply to the table

  • 8/9/2019 Excel2007 Advanced

    31/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 30 of 107

    Creating Pivot Charts

     A pivot chart is used to summarise and analyse data from an existing list or worksheet. A pivot chartis made up of series fields, category fields and page fields.

    This data list:

    Could be used to produce this PivotChart:

    Creating a PivotChart

    To create a PivotChart from a data list or table of information:

      Click on any cell of the list or table

      Click on the Insert ribbon

      Click on the drop-down arrow of the PivotTable button in the Tables group

      Ensure the data list range is correct

      Choose the location for the PivotChart. Choose New Worksheet to place the PivotChart on a newchart sheet in the current book or Existing Worksheet to place the PivotChart as an object on anexisting sheet

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    32/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 31 of 107

     A blank PivotTable and PivotChart is created, with a task bar on the right-hand side where the PivotChart isbuilt:

    To add a field to the PivotChart, drag the field from the field

    list to the relevant area of the task pane.

      Choose the field you wish to show in the legend anddrag this to the Legend Fields box

      Choose the field you wish to show along the categoryaxis of the chart and drag this to the Axis Fields box

      Choose the field that contains the values you wish toplot on the chart and this to the Values box

       As you add fields to the task pane, the PivotTable andPivotChart will build automatically on the worksheet.

  • 8/9/2019 Excel2007 Advanced

    33/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 32 of 107

    Hiding Entries

    The PivotChart need not include all data from the underlying list - it is possible to hide specific categories or

    entries.

      On the PivotChart Filter Pane, click on the drop-down arrow of the Axis Field or  Legend Field -whichever you wish to hide entries from

      Click on the check box of each item you wish to exclude

      Click on OK when complete

    Freezing PanesIf your data list contains more records than will fit on a single screen, you will have to scroll down toview records that appear towards the end of your list. As you scroll down, you will lose the headingsat the top of the list.

      To solve this problem, you can freeze your headings on screen so that they always show alongthe top.

      Click on the View ribbon

      Click on the drop-down arrow of the Freeze Panes button

      Choose Freeze Panes to freeze all rows above the active cell, and all columns to the left of theactive cell or  

      Choose Freeze Top Row to freeze the top row of the data list or  

      Choose Freeze Left Column to freeze the left column of the data list

  • 8/9/2019 Excel2007 Advanced

    34/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 33 of 107

    Unfreeze the titles by clicking on the drop-down arrow of the Freeze Panes button and choose the Unfreeze

    Panes option.

    Database Functions

    Database functions are used to analyse relevant records in a data list. Only the records that matchthe specified criteria will be analysed - any records that don't match this criteria will be ignored.

    The following functions can be used to analyse a data list.

    Function Example Description

    DSUM =DSUM(Database, "Field",Criteria)

     Adds the contents of the specified field of thedatabase, but only for those records that matchthe criteria.

    DAVERAGE =DAVERAGE(Database, "Field",Criteria)

    Finds the average of the specified field of thedatabase, but only for those records that matchthe criteria.

    DMAX =DMAX(Database, "Field",Criteria)

    Returns the largest value in the specified field ofthe database, but only for those records thatmatch the criteria.

    DMIN =DMIN(Database, "Field",Criteria)

    Returns the smallest value in the specified fieldof the database, but only for those records thatmatch the criteria.

    In the following example, the area shaded in yellow is the database range, while the area shaded in

    blue is the criteria. The DSum command is used in the pink shaded area to calculate the total balanceof all customers in London:

  • 8/9/2019 Excel2007 Advanced

    35/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 34 of 107

    When using database functions, range names can be used to save time and make the formulaseasier to create.

      Select the database range

      Click in the name box above the column headings and type a name for the range e.g. data 

      Press [Return]

      Select the criteria range  Click in the name box above the column headings and type a name for the range e.g. criteria 

      Press [Return]

      Once the names have been applied, they can be used in the formula as required. The followingformula would calculate the average balance of all records in the range named data that matchthe criteria in the range named criteria:

      =DSUM(database,"balance",criteria)

  • 8/9/2019 Excel2007 Advanced

    36/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 35 of 107

    The Names Manager

    Range names can be set to refer to any range of cells. The Name Manager allows you to check the

    value and formula entered in named ranges, even if these cells are no longer in view on yourworksheet. You can also use the Name Manager to edit and delete range names.

    Displaying the Name Manager

    To display the Name Manager:

      Click on the Formulas ribbon

      Click on the Name Manager  button in the Defined Names group

    The Name Manager will be displayed:

    Adding Range Names

    To add a range name to the worksheet:

      Click on the New button

      Enter a range name in the Name box

      Choose the Scope for the name i.e. how the name will be accessible. Choose Workbook if youwish to be able to refer to the name from any sheet of the workbook

       Add any comments to describe the range

      Click in the Refers To box, then select the range that the name should refer to in the worksheet

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    37/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 36 of 107

    You can show the Name Manager on any sheet to see the values in the named ranges in your worksheet.

    Removing Range Names

    To remove a range name from the worksheet:

      Click on the Formulas ribbon

      Click on the Name Manager  button in the Defined Names group

      Select the name you wish to remove

      Click on the Delete button

    This will remove the name from the cell, but leave the cell as is on the worksheet.

    Amending Range Names

    To amend the range that a name is referring to:

      Click on the Formulas ribbon

      Click on the Name Manager  button in the Defined Names group

      Select the name you wish to amend

      Click in the Refers To box at the bottom of the Name Manager and amend the range as required

      Click on the tick button to save the change to the range

  • 8/9/2019 Excel2007 Advanced

    38/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 37 of 107

    The Scenario Manager

     A scenario is a named set of values that can be substituted into a range of a worksheet. Any formula

    referring to this range will be updated accordingly. The Scenario Manager is extremely useful forcomparing the impact of different sets of values on the rest of the worksheet.

    This worksheet shows a best-case scenario for profit, with high revenue and comparatively low cost. Cells

    B1 and B2 could be saved as a scenario called Best.

    This version of the same worksheet shows a worst-case scenario, with low revenue and high cost. Cells B1

    and B2 could be saved as a scenario called Worst.

    You could switch between the scenarios easily, to see how each impacts all formulas on the worksheet.

    Creating Scenarios

    To create a scenario:

      Select the cells you wish to save as a scenario

      Click on the Data ribbon

      Click on the What-if Analysis button in the Data Tools group

      Choose Scenario Manager  

      The Scenario Manager will display - click on the Add button to add a new scenario

      Enter a name for the scenario in the Scenario Name box

      Ensure the Changing Cells box refers to the correct range in the worksheet

      Click on OK 

  • 8/9/2019 Excel2007 Advanced

    39/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 38 of 107

    The Scenario Values box will display. Enter the values you want to store in the selected cells for thisscenario

      To create another scenario for the same range, click on Add 

      Enter a new Scenario Name and click on OK 

      The Scenario Values box will display. Enter the values you want to store in the selected cells forthis scenario

      Repeat the above steps to add more scenarios for the same cells, or click on OK when complete

      Click on Close to return to the worksheet

  • 8/9/2019 Excel2007 Advanced

    40/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 39 of 107

    Displaying Scenarios

    To display a particular scenario in your worksheet:

      Click on the Data ribbon

      Click on the What-if Analysis button in the Data Tools group

      Choose Scenario Manager  

      Choose the scenario you wish to display, then click on Show 

    You can remove a scenario in the Scenario Manager window by clicking on the name of the scenario, then on

    the Delete button.

    Summary Reports

    The Summary button in the Scenario Manager window can be used to print summary reports about the

    scenarios in the worksheet and their associated values.

    The following reports can be displayed:

    Report Description

    Summary Select this option to create an outlined summary report on a separate sheet of theworkbook. The summary report will show the current values in the changing cells,the values in each scenario and any cells that are affected by the scenarios

    PivotTable Select this option to create a pivot table on a separate worksheet. This pivot tablewill contain a page field listing all users that have created scenarios in theworksheet

  • 8/9/2019 Excel2007 Advanced

    41/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 40 of 107

    Goal Seek

    The Goal Seek command is used to change the result of a formula by changing the value of a cell that

    the formula is dependent on.

      Imagine you know the required profit to be made in a certain month, and would like to know thesales needed to make that profit.

      Cell B1 contains the sales figure as a normal value

      Cell B2 calculates the cost of sales at 35% of the sales figure using the formula =B1*35% 

      Cell B3 calculates the profit as sales less cost using the formula =B1-B2 

      The goal seek command could be used to change the profit (B3) to a particular result byincreasing or decreasing the sales, and therefore also changing the cost.

    Using the Goal Seeker

    To use the Goal Seek command to change your formula's result:

      Select the formula you wish to change the result of

      Click on the Data ribbon

      Click on the What-if Analysis button in the Data Tools group

      Choose Goal Seek

      Click in the To Value box and type the desired result for the selected formula

      Click in the By Changing Cell box and either type or select the cell that should change to updatethe formula result

      Click on OK to show the proposed result

      Choose OK to set the proposed value, or Cancel to leave as is

  • 8/9/2019 Excel2007 Advanced

    42/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 41 of 107

    The Goal Seek command allows you to change only one value to reach your desired goal.

    Data Tables

    Data tables can supply several answers to a calculation by substituting different values into a formula. A one-way data table is used to substitute only one value of the formula, while a two-way data table isused to substitute two values.

    One Way Data Tables

    One way data tables are used when we have only one value that differs in each formula. In the following

    example, we want to work out multiple prices, each based on a different discount percentage.

    In this example, the formula in cell B4 calculates the price multiplied by the discount using the formula

    =B1*B2. B2 will become the input cell that all values in the first column of the data table range (A4:B11) will

    be substituted into in turn.

    To create the data table:

      Enter the range of substitute values into a single column (as we have in cells A5 to A11 above)

      In the row above and one column to the right of this column, enter the first formula to becalculated. At the place in the formula where the value should be substituted, use the address ofany cell outside the data table area. This is known as the input cell, and our input cell in the aboveexample is B2

      Type any other formula to be calculated to the right of the first. Use the same input cell in eachformula

      Select the range of cells containing the substitute values and formulas but not the input cell

    (A4:B11 in the above example)

      Click on the Data ribbon

      Click on the What-if Analysis button in the Data Tools group

  • 8/9/2019 Excel2007 Advanced

    43/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 42 of 107

      Choose Data Table

      Click in the Column Input Cell box and type the reference of the input cell

      Click on OK to calculate all results

    For the above example, the following results would be shown:

    Two Way Data Tables

    Two way data tables are used when we have two values that differ in each formula. In the following

    example, we want to work out multiple prices, each based on a different discount percentages and different

    starting prices.

    In this example, the formula in cell A4 calculates the price multiplied by the discount using the formula

    =B1*B2. Both B1 and B2 will become input cells. The first row of values (B4:F4) will be substituted into cell

    B1, while the first column of values (A5:A11) will be substituted into B2.

  • 8/9/2019 Excel2007 Advanced

    44/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 43 of 107

    To create the data table:

      Enter the first set of substitute values in a single row (as we have in cells B4:F4 above)

      Enter the second set of substitute values in a single column (as we have in cells A5:A11 above)

      In the corner cell type the formula to be calculated. At the place in the formula where the valuefrom the first or second set should be substituted, use the address of any cells outside the datatable area. Different input cells must be used for each set of values

      Select the range of cells containing the substitute values and formulas but not the input cells(A4:F11 in the above example)

      Click on the Data ribbon

      Click on the What-if Analysis button in the Data Tools group

      Choose Data Table

      Click in the Row Input Cell box and type the reference of the first input cell (B1 in our example)

      Click in the Column Input Cell box and type the reference of the second input cell (B2 in ourexample)

      Click on OK to calculate all results

  • 8/9/2019 Excel2007 Advanced

    45/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 44 of 107

    For the above example, the following results would be shown:

    Creating If Statements

    Basic If Statements

    The =IF function performs a conditional calculation. The function tests a condition to see whether it is true

    or false. One result is displayed if the condition is true, another if it is false.

    The syntax is =IF(Condition, Result if True, Result if False) 

    The standard comparison operators are used to enter the condition:

    Operator Meaning

    = Equal to

    > Greater than

    >= Greater than or equal to

    < Less than

  • 8/9/2019 Excel2007 Advanced

    46/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 45 of 107

    For example: 

    If the figure in cell A1 is greater than 2000, the current cell should calculate 5% of the figure in A1. If not,

    the current cell should contain zero.

    If Statements with Multiple Conditions

    The And( ) and Or( ) functions are used to test more than one condition at the same time. The And() 

    function is used to test multiple conditions when ALL conditions must be met for the condition to be true.

    The syntax of the AND statement is: =IF(AND(Condition 1, Condition 2), Result if True, Result if False)  

    The OR() function is used to test multiple conditions when only ONE of the conditions must be met for the

    condition to be true.

    The syntax of the OR statement is: =IF(OR(Condition 1, Condition 2), Result if True, Result if False) 

    To enter an IF statement using AND() or OR():

      Click in the cell to contain the formula result

      Type =IF and open brackets ( 

      Type And if all conditions should be met, or Or if only one condition should be met, then open afurther set of brackets ( 

      List all conditions separated by commas and close brackets ) 

      Type a comma and the result to be shown if ALL conditions are met (if using And) or only onecondition is met (if using Or )

      Type another comma and the result to be shown if the conditions are not met

      Close brackets ) to end the formula

    For example: 

    If both figures in cell A1 and A2 are greater than 2000, the current cell should calculate 5% of the sum of

    these figures. If either is less than 2000, the current cell should contain zero.

  • 8/9/2019 Excel2007 Advanced

    47/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 46 of 107

    Nested If Statements

    Nested =IF statements are used when more than one result can be given depending on the criteria met.

    Instead of a single result if true or false, another IF statement is started and another condition tested.

    There can be up to 7 levels of nesting in an IF statement:

      Click in the cell to contain the formula result

      Type =IF and open brackets ( 

      Type the first condition to be tested and type a comma

      If the result if true is a value or formula, type the value or formula and type a comma. If anothercondition should be tested, type the IF statement including the result if true and result if false.Close the brackets of the nested IF

      Type a comma and enter the main statement's result if false. If this is a value or formula, type thevalue or formula. If another condition should be tested, type the IF statement including the resultif true and result if false. Close the brackets of the nested IF and the main IF.

    For example: 

    If the figures in cell A1 is greater than 2000, 200 is returned. If not, it is tested again. If it is greater than

    1000, 100 is returned. If not, 0 is returned.

    Creating Lookup Statements

    Lookup functions are similar to =IF functions in that they return a value based on a condition. Thefunction looks for the criteria in a table of values and returns the matching value from that table.

    VLOOKUP Functions

    VLOOKUP is used when the lookup table is entered in columns (i.e. vertical).

    The following example will look up the value of B1 in the table stored in D2:F6. The result in the third

    column of the corresponding row will be displayed.

  • 8/9/2019 Excel2007 Advanced

    48/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 47 of 107

    To enter a VLOOKUP function:

      Click on the cell to contain the formula result

      Type =VLOOKUP and open brackets (

      Click on or type the reference of the lookup cell and type a comma

      Select or type the range of the table containing the values. The first column of this table shouldcontain the values to be matched and should be displayed in ascending order. If the range hascolumn headings, these should not be included in the selection

      Type a comma, then type the number of the column that contains the value to be displayed (1being the left-most column)

      Close brackets ) 

      Press [Enter]

    If the function cannot find an exact match for the lookup value, it finds the largest value that is less than the

    lookup value.

    Using the above example, if cell B1 contained 8, the value 2700 would be returned, even though there is no

    application with a code of 8. As 5 is the closest match, the value of this application is given.

    This default can be changed by adding FALSE to the end of the lookup statement. Instead of returning the

    closest match, an error message will be returned if an exact match is not found.

    Using the above example, the function could be updated to: =VLOOKUP(B1,D2:F6,3,FALSE)

    HLOOKUP Functions

    HLOOKUP is used when the lookup table is entered in rows (i.e. horizontal).

    The following example will look up the value of B1 in the table stored in D2:F6. The result in the third

    column of the corresponding row will be displayed.

    To enter a HLOOKUP function:

      Click on the cell to contain the formula result

      Type =HLOOKUP and open brackets (

      Click on or type the reference of the lookup cell and type a comma

      Select or type the range of the table containing the values. The first row of this table shouldcontain the values to be matched and should be displayed in ascending order. If the range hasrow headings, these should not be included in the selection

      Type a comma, then type the number of the row that contains the value to be displayed (1 beingthe top row)

      Close brackets ) 

      Press [Enter]

  • 8/9/2019 Excel2007 Advanced

    49/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 48 of 107

    Error Trapping

    Excel has a number of functions that can be used to find errors and other types of values in cells. Each

    function returns TRUE or FALSE depending on whether the error or value is found in the cell.

     Available functions:

    Function Description

    =ISBLANK(cell) Returns TRUE if the specified cell is blank

    =ISERROR(cell) Returns TRUE if the specified cell contains an error

    =ISERR(cell) Returns TRUE if the specified cell contains an error other than #N/A

    =ISTEXT(cell) Returns TRUE if the specified cell contains text

    =ISNUMBER(cell) Returns TRUE if the specified cell contains a number

    For example:

      Cell B1 contains the =ISERROR(A1) function and returns true as there is an error in cell A1

      Cell B2 contains the same function and returns false as there is no error in cell A2

      Cell B3 contains the =ISNUMBER(A3) function and returns true as there is a number in cell A3

      Cell B4 contains the same function and returns false as there is no number in cell A4

    Error functions are often combined with IF statements to give different results in a cell depending on

    whether a condition is true or false.

    For example: 

    The following example attempts to divide cell A1 by B1. If the division would return an error, the cell will

    remain blank. If the division will not return an error, the result will be displayed. This formula has been

    copied to the next row, which is blank as an error has occurred when attempting to divide by 0.

  • 8/9/2019 Excel2007 Advanced

    50/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 49 of 107

    Excel Error Messages

    The following error messages occur when entering a formula in Excel:

    Error Meaning

    #### This is not actually an error message but simply means that the column is not wideenough to display the result of the formula - widening the column will fix the error

    #DIV/01 The formula is trying to divide by 0. This error can also occur if you are dividingtext rather than values

    #N/A No value is available. This error commonly occurs in Lookups when the lookup celldoes not yet contain a value

    #NAME? This formula is either referencing a range name that does not exist or is using afunction which is misspelled e.g. =SUMM instead of =SUM

    #NUM! There is a problem with a number in the formula. This is often caused by a functionusing an unacceptable argument e.g. using a negative number in a function that

    will only accept positive numbers

    #REF! The formula refers to a cell that is not valid. This can be caused by deleting cellsthat other formulas refer to or pasting moved cells over cells that other formulasrefer to

    #VALUE! An incorrect argument has been used. This can be caused by referencing a rangeof cells when a single cell is required or referencing text when a number is required

    Date and Text Functions

    Date Functions

    The following functions can be used to insert dates and times into the worksheet:

    Function Description

    =today() Returns the current date which will update each time the file is opened

    =now() Returns the current date and time which will update each time the file isopened

    The following functions can be used to manipulate dates in the worksheet:

    Function Syntax Description

    Day =DAY(date) Returns the day number from the specified date, from 1 to 31

    Month =MONTH(date) Returns the month number from the specified date, from 1(January) to 12 (December)

    Year =YEAR(date) Returns the year as a value e.g. 2007

    Weekday =WEEKDAY(date) Returns a value representing the day of the week that thedate falls on, where 1 is Sunday and 7 is Saturday

    Weeknum =WEEKNUM(date) Returns the week number in the year, from 1 to 52

    Remember you can find out the number of days between two dates by subtracting the earlier date from the later

    date.

  • 8/9/2019 Excel2007 Advanced

    51/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 50 of 107

    Text Functions

     As well as manipulating values in a spreadsheet, it is also possible to create formula to manipulate text. For

    example, two or more cells can be concatenated using the & operator. In the following spreadsheet, the

    name and surname have been concatenated to return the full name:

    Whenever text or spaces are added to the formula, be sure to enclose these in quotation marks. Quotation

    marks are never needed for cell references or range names.

    The following text functions can also be used to manipulate text in cells.

    Function Syntax Description

    Find =FIND("Text", Reference) Searches for Text in thereferenced cell and returns thecharacter number where the textstarts

    Replace =REPLACE(Reference, Starting Cell, Number,"Text")

    From the starting character, thespecified number of characterswill be replaced with the Text.

    The new cell content is returned.Len =LEN(Reference) Returns the number of

    characters in the specified cell

    Trim =TRIM(Reference) Returns the cell contents with allextra spaces removed

    Left =LEFT(Reference, Number of Characters) Returns the specified number ofcharacters from the left of thespecified cell

    Right =RIGHT(Reference, Number of Characters) Returns the specified number ofcharacters from the right of thespecified cell

    Mid =MID(Reference, Starting Character, Number ofCharacters)

    Returns the specified number ofcharacters from the givenstarting position of the cell

    Upper =UPPER(Reference) Returns the content of the cell inupper case

    Lower =LOWER(Reference) Returns the content of the cell inlower case

    Proper =PROPER(Reference) Returns the content of the cell inproper case (initial caps)

  • 8/9/2019 Excel2007 Advanced

    52/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 51 of 107

    Auditing Workbooks

    The Formula Auditing group on the Formulas ribbon is used to trace cells and errors in a worksheet.

      To trace precedents, the cells that the selected formula refers to, click on a formula and then onthe Trace Precedents button on the Formulas ribbon

      To trace dependents, cells that contain formulas that refer to the active cell, click on any cell andthen on the Trace Dependents button on the Formulas ribbon

      Click on the Remove All Arrows button to remove tracing arrows

      The Formula Auditing group also contains a button that can be used to trace errors. This featurewill try to locate the cell that is causing the error in the formula.

      Click on the cell that contains the error

      Click on the drop-down arrow of the Error Checking button on the Formulas ribbon

      Choose Trace Error  

  • 8/9/2019 Excel2007 Advanced

    53/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 52 of 107

     Arrows will show the cells that the formula refers to, which should allow you to see where the errorlies:

    Use the Show Formulas button on the Formulas ribbon to replace formula results with the formulas

    themselves, for evaluation and checking purposes.

    The Watch Window

    The Watch Window allows you to check the value and formula entered in specific cells, even if thesecells are no longer in view on your worksheet. The watch window updates automatically as the cellschange, allowing to you see at a glance what their results are.

      To show the watch window:

      Click on the Formulas ribbon

      Click on the Watch Window button in the Formula Auditing group

      The watch window will display:

    You can move the watch window by dragging the title bar of the window to a new position.

    To add a cell to the watch window, so that you can always see the value in that cell:

      Click on the cell you wish to add to the watch window

      Click on the Add Watch button near the top left of the watch window

      Click on Add to confirm the cell to be added

  • 8/9/2019 Excel2007 Advanced

    54/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 53 of 107

      You will be able to see the workbook name, sheet name, any range names applied to the cell, thecurrent value and any formula entered in the cell:

      To remove a cell from the watch window, click on the cell reference, then on the Delete Watch

    button.

    Close the watch window using the X in the top-right corner of the window.

    Accessing Add-Ins

     An Add in is a small program that allows you to add additional features and custom commands to Excel

    2007.

    Some standard Add-ins are available with Excel but you will need to install them after you have installed

    the Excel program. In order to access the Excel Add-ins you will need to have the original Microsoft Office

    disks, or have access to the Internet to obtain the add-ins from Microsoft's web site.

    The following standard Excel add-ins are available:

    Add-In Description

     Analysis ToolPak Adds, Financial, statistical and analysis tools and functions

     Analysis ToolPak

    VBA

     Allows developers to use the analysis ToolPak features in their macros and

    solutions

    Conditional SumWizard

    Creates a formula that sums data in a list if it matches your specified criteria

    Euro CurrencyTools

    Formats values in Euros and allows the EUROCONVERT function to work

    Internet AssistantVBA

     Allows developers to publish Excel VBA code and programs to the Web

    Lookup Wizard Creates a formula to look up data in a list by using another known value in thatlist

    Solver Add-In Allows users to add in complex business scenarios and work out solutions,

    based on adjustable cells and constraints

     Additional Add-Ins are available from the Microsoft Web site at www.microsoft.com 

    http://www.microsoft.com/http://www.microsoft.com/http://www.microsoft.com/http://www.microsoft.com/

  • 8/9/2019 Excel2007 Advanced

    55/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 54 of 107

    To install an Excel add-in:

      Click on the Office button, then on the Excel Options button

      Click on the Add-Ins menu option on the left-hand side of the window

      Click on the Go button next to Manage Excel Add-Ins 

      Check each add-in you wish to install

      Click on OK 

    You will be asked to confirm that you wish to install each add in - click on Yes to continue:

  • 8/9/2019 Excel2007 Advanced

    56/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 55 of 107

    The add-in will be installed:

    Calculation Options

    Excel 2007 will automatically update all calculations in your workbook each time it is opened. Theworkbook will also recalculate each time you enter a new formula, to ensure all other formulas in theworksheet are up-to-date.

    If your spreadsheet is large and contains many formulas, this can result in waiting time while Excelupdates all formulas. If you prefer, you can set the Excel to manual calculation - all formulas will onlyupdate when you specify they should.

      To set the calculation type:

      Click on the Formulas ribbon

      Click on the drop-down arrow of the Calculation Options button

      Choose Manual 

      Once the calculation has been set to manual, you can choose to re-calculate when it suits you.

      To recalculate and update all formulas, either:

      Click on the Calculate Now button on the Formulas ribbon to recalculate the entire workbook

      Click on the Calculate Sheet button on the Formulas ribbon to recalculate the current worksheetonly

    You can also use the following shortcuts to recalculate:

    Keystroke Action

    F9 Calculate workbook

    Shift F9 Calculate current worksheet only

  • 8/9/2019 Excel2007 Advanced

    57/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 56 of 107

     Additional calculation options can be set by clicking on the Office button, then on the Excel Options button.

    Click on the Formulas menu on the left-hand side of the window.

    Linking FormulasLinking Formulas

    It is possible to include cells from any sheet in a formula.

    For example, the formula =A3-B3 refers to these cells on the current sheet but can be changed to

    =Sheet1!A3-Sheet2!B3 to refer to cells on sheets 1 and 2, regardless of the sheet in which the formula is

    typed.

    It is also possible to refer to a range of cells spanning several sheets. The following formula will sum the

    values in cell A3 of all sheets, from the sheet named January to the sheet named June:

     A link to another workbook can also be created by entering a reference to the target range using the

    syntax: =[file.xls]sheet!cell. In the following example, the formula refers to cell A10 on the sheet named

    Jan in the sales.xlsx file stored in the same directory as the current workbook.

    Paste Link

    Data can be linked from one worksheet to another, even if the sheets are not in the same workbook.

    The original data is known as the source while the copy is known as the target or destination. Whenever

    the source changes, the target will be updated accordingly.

      Select the source data

      Click on the Copy button on the Home ribbon, or press [Ctrl C]

  • 8/9/2019 Excel2007 Advanced

    58/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 57 of 107

      Select the target cell for the data to start in

      Click on the drop-down arrow of the Paste button on the Home ribbon

      Choose Paste Special 

      Click on the Paste Link button in the Paste Special window

    The data will be copied and linked to the original workbook. If the original changes, the target will update when it

    is next opened.

  • 8/9/2019 Excel2007 Advanced

    59/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 58 of 107

    Maintaining Links

    Worksheet links are updated each time the target file is opened or recalculated. If the source file's location

    changes, it can be edited so further updates can be made:

      Click on the Data ribbon

      Click on the Edit Links button in the Connections group

     All links will be listed in the Edit Links window:

      If the file has moved, click on the Change Source button and locate the moved file. Click on OK 

      To check the status of the link, click on the Check Status button. You will be told if the source isOK or cannot be found

      To stop linking to a file, click on the link, then on the Break Link button. Click on Break Links toconfirm this

      Click on Close to return to the worksheet

  • 8/9/2019 Excel2007 Advanced

    60/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 59 of 107

    Adding Comments

    Comments can be attached to any cells in the worksheet to add explanations about formula,

    worksheet layout, etc.

    Setting your User Name

    By default, comments will display the name of the user that inserted the comment. Ensure the correct user

    name is set before inserting a comment.

      Click on the Office button

      Click on the Excel Options button

      With the Popular  menu selected on the left-hand side of the window, click in the User Name box

      Enter your user name, then click on OK 

    Adding Comments

    To insert a comment:

      Click on the cell you want to add a comment to

      Click on the Review ribbon

      Click on the New Comment button in the Comments group

       A new comment will be created containing your User Name which can be selected and deleted oredited as required

      Type the comment text

      Click on any cell in the worksheet to secure the comment

  • 8/9/2019 Excel2007 Advanced

    61/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 60 of 107

    Press [Shift F2] to quickly add a comment to the active cell.

    Viewing Comments

     A red triangle will display in the corner of a cell that contains a comment:

    The comment will display when the mouse is positioned over the cell:

    By default, comments are only displayed when the mouse is positioned over the cell. A single comment can

    be displayed permanently as follows:

      Click on the cell containing the comment

      Click on the Show/Hide Comment button on the Review ribbon

     Alternatively, display all comments in the workbook by clicking on the Show All Comments button on the

    Review ribbon.

  • 8/9/2019 Excel2007 Advanced

    62/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 61 of 107

    Editing and Removing Comments

    To edit a comment:

      Click on the cell containing the comment

      Click on the Edit Comment button on the Review ribbon

      Edit the text as required

      Click on any cell of the worksheet when complete

    To remove a comment:

      Click on the cell containing the comment

      Click on the Delete button in the Comments group of the Review ribbon

    You can also right-click over a cell containing a comment to see options to delete and edit the comment:

    Printing Comments

    Comments can be printed as they appear in the worksheet or listed together at the end of the printout.

     As displayed on the sheet:

  • 8/9/2019 Excel2007 Advanced

    63/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 62 of 107

     At the end of the sheet:

    To set how comments will print:

      Click on the Page Layout tab

      Click on the More Information button in the Page Setup group

      Click on the Sheets tab of the Page Setup window

      Click on the drop-down arrow of the Comments box and choose the required print option

      Click on OK   Print or preview the worksheet as normal

    If you wish to print comments as they appear, ensure all comments are displayed before the Print command is

    used.

    Sharing a Workbook

    Opening Workbooks Already in Use

    By default, if you open a workbook stored on a shared drive that is currently open on another user's

    computer, a message similar to the following will display:

  • 8/9/2019 Excel2007 Advanced

    64/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 63 of 107

      Click on Read Only to open a read-only version of the file - you will not be allowed to save anychanges you make to the workbook.

      Click on Notify to open a read-only version of the file. When the original user has closed theworkbook, you will be given the chance to switch to read/write mode so that any changes can besaved

    Sharing Workbooks

    It is possible for more than one user to work on an Excel file at the same time, provided it has been set up

    as a shared workbook. Some features are not available when a workbook is shared:

      Inserting or deleting cells - although entire columns/rows can be inserted or deleted

      Inserting images, shapes and objects

      Creating charts

      Creating PivotTables

       Applying conditional formatting or formatting as tables

      Importing data

    To set the current workbook so that it can be shared by other users:

      Click on the Review ribbon

      Click on the Share Workbook button in the Changes group

      Check the Allow changes box

      Click on OK 

      You will be told that the workbook will be saved - click on OK 

  • 8/9/2019 Excel2007 Advanced

    65/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 64 of 107

    When a workbook has been set to shared, a new indicator will appear in the Title Bar:

    Sharing Conflicts

    To view a list of users currently working with the workbook:

      Click on the Review ribbon

      Click on the Share Workbook button in the Changes group  Ensure the Edit tab is selected - a list of all users will be displayed:

    Conflicts will occur when two or more users make different changes to the same cell and attempt to save

    the file.

    The Resolve Conflicts dialog box will display when you attempt to save a change that conflicts with another

    change saved in the current session:

      Click on Accept Mine to keep the change that you made in the sheet

      Click on Accept Other  to use the change made by the other user, discarding your own change

      Click on Accept All Mine to keep all changes made by yourself, with no further prompts

      Click on Accept All Others to keep all changes made by other users, with no further prompts

  • 8/9/2019 Excel2007 Advanced

    66/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 65 of 107

    To make the workbook exclusive again, click on the Share Workbook button and uncheck the Allow

    changes box. Any users currently accessing the file will not be allowed to save their changes.

    Tracking Changes

    In a shared workbook you can have Excel highlight any changes that you, or any other user who hasaccess to the spreadsheet makes. Excel will track additions, deletions and cell changes and allow youto review the changes and decide which ones you would like to accept.

      To highlight changes made to the workbook:

      Click on the Review ribbon

      Click on the Track Changes button in the Changes group

      Choose Highlight Changes

      Click on the Track Changes checkbox, to start tracking changes and share your workbook

      Click on the drop-down arrow of the Who box to specify the users whose changes you want totrack - leave on Everyone to track all changes

      Click in the Where box and specify the range you want to track changes in - leave blank to trackchanges to the entire workbook

      Click on the Highlight Changes on Screen option to have the changes displayed on yourworksheet

      Click on OK 

      You will be told that the workbook will be saved - click on OK 

  • 8/9/2019 Excel2007 Advanced

    67/108

    Excel 2007 Advanced

     © Hewlett-Packard 2007 Page 66 of 107

      Once you have enabled the tracking option, any additions, deletions or edits made to thespreadsheet will be tracked by date and user. Amended cells will be highlighted by a blue borderand corner triangle - position the mouse over a highlighted cell to view details of the change:

    Accepting and Rejecting Changes

     After changes have been made, and in particular if there are conflicting changes, it is necessary toreview the changes and decide which should be kept.

      To accept or reject changes:

      Click on the Review ribbon

      Click on the Track Changes button in the Changes group

      Choose Accept/Reject Changes

      Choose the