0% found this document useful (0 votes)
21 views146 pages

ICT122 Manual 2023

BUAN tight. Right I meant to say

Uploaded by

Olorato
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views146 pages

ICT122 Manual 2023

BUAN tight. Right I meant to say

Uploaded by

Olorato
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 146

23 February

2023

ICT122 Practical
Manual 2022
Presentation, Spreadsheet, and Database Basics
using Microsoft Office 2019

Compiled by: ICT FACILITATORS


ICT SECTION - BOTSWANA UNIVERSITY OF AGRICULTURE AND
NATURAL RESOURCES (BUAN)

Office 2019: PowerPoint Excel, and Access


TABLE OF CONTENTS
ICT LABORATORY RULES AND REGULATIONS ............................................................................ x
WEEK 2: MICROSOFT POWERPOINT 2019 ................................................................................ 1
OBJECTIVES ......................................................................................................................... 1
INTRODUCTION................................................................................................................... 1
THE DESIGN RIBBON TOOLBAR ............................................................................................ 2
CREATING SLIDES ................................................................................................................ 2
Adding Text to a Slide ................................................................................................................ 3
Adding another Slide ................................................................................................................. 3
Moving from Slide to Slide ........................................................................................................ 4
Outline View .............................................................................................................................. 4
Switching to Outline View ......................................................................................................... 4
Adding a Slide in the Outline View ............................................................................................ 4
Adding Text to the Outline View ............................................................................................... 5
Moving around in Outline View ................................................................................................ 5
Moving from One Slide to the Next Slide.................................................................................. 6
WHAT IS A TEMPLATE/DESIGN? .......................................................................................... 6
Creating a Presentation Using Templates ................................................................................. 6
Making Changes to Presentation .............................................................................................. 6
Resizing a Text Box .................................................................................................................... 6
Adding a New Text Box ............................................................................................................. 7
Deleting a Text Box.................................................................................................................... 7
Outlining a Text Box .................................................................................................................. 7
Changing Font............................................................................................................................ 8
Selecting a New Bullet Style ...................................................................................................... 8
Changing Background Colour .................................................................................................... 9
ADDING IMAGES AND CHARTS ............................................................................................ 9
Adding a Shape .......................................................................................................................... 9
Moving a Shape ....................................................................................................................... 10
Adding Colour and Texture to a Shape ................................................................................... 10
Class Exercise:.......................................................................................................................... 10
Layering images ....................................................................................................................... 11
Adding shadows to images ...................................................................................................... 11
Adding a chart ......................................................................................................................... 11
Adding a table ......................................................................................................................... 12

Office 2019: PowerPoint Excel, and Access i


ADDING MOTION ...............................................................................................................12
Switching to Slide Sorter View ................................................................................................ 12
Moving Slides Around ............................................................................................................. 12
Adding a Transition ................................................................................................................. 13
Timing a Transition .................................................................................................................. 13
Adding Animation to an Object ............................................................................................... 14
Class Exercise:.......................................................................................................................... 14
Creating Speaker Notes ........................................................................................................... 14
Timing the Presentation .......................................................................................................... 14
PRINTING SLIDES ................................................................................................................15
Print Preview ........................................................................................................................... 15
Print Layout ............................................................................................................................. 15
WEEK 3: CREATING, ORGANISING AND FORMATTING AN MICROSOFT EXCEL WORKBOOK 2019
..............................................................................................................................................17
OBJECTIVES ........................................................................................................................17
INTRODUCTION..................................................................................................................17
STARTING THE PROGRAM ..................................................................................................18
EXPLORING THE USER INTERFACE: EXCEL PROGRAM WINDOW...........................................18
EXCEL RIBBON ................................................................................................................20
To Customize the Ribbon ........................................................................................................ 20
To Minimize and Maximize the Ribbon: ................................................................................. 21
TO OPEN AN EXISTING WORKBOOK....................................................................................21
Frequently Used Shortcuts ...................................................................................................... 21
COMPATIBILITY MODE .......................................................................................................22
To Convert a Workbook: ......................................................................................................... 23
ENTERING DATA .................................................................................................................23
Entering Text ........................................................................................................................... 23
Entering Numbers ................................................................................................................... 23
OPENING A NEW WORKBOOK ............................................................................................24
Modify Column Width ............................................................................................................. 24
Modify the Row Height ........................................................................................................... 24
Set Column Width with a Specific Measurement ................................................................... 25
WORKING WITH COLUMNS AND ROWS ..............................................................................25
Selecting Rows and Columns................................................................................................... 25
Select a Single Row or Column ................................................................................................ 25
Select Multiple Adjacent Rows or Columns ............................................................................ 26

Office 2019: PowerPoint Excel, and Access ii


Select Multiple Non-Adjacent Rows or Columns .................................................................... 26
Inserting Rows and Columns ................................................................................................... 26
Inserting Columns.................................................................................................................... 26
Deleting Rows and Columns .................................................................................................... 27
FILL HANDLE.......................................................................................................................27
Moving Cell Contents .............................................................................................................. 28
Inserting Rows and Columns ................................................................................................... 28
Inserting Columns.................................................................................................................... 28
Deleting Rows and Columns .................................................................................................... 28
CONTROLLING SPREADSHEETS ...........................................................................................29
Find, Replace, Go To ................................................................................................................ 29
Class Exercise 1: Find, Replace, Go To..................................................................................... 29
Hide and Unhide Rows or Columns ......................................................................................... 30
Hide and Unhide a Worksheet ................................................................................................ 30
Hide and Unhide a Workbook. ................................................................................................ 30
Splitting a Worksheet into Two Parts...................................................................................... 30
Merge or Split Cells ................................................................................................................. 31
Merge and Center Cells ........................................................................................................... 31
Merge Cells .............................................................................................................................. 31
Split Cells ................................................................................................................................. 31
Wrapping Text ......................................................................................................................... 31
Freezing Panes......................................................................................................................... 32
Freezing/Splitting Rows and Columns..................................................................................... 32
Freezing vs. Splitting ................................................................................................................ 32
Freeze Panes............................................................................................................................ 32
Unfreeze Panes........................................................................................................................ 33
Split Panes ............................................................................................................................... 33
Password Protect a Worksheet or Workbook......................................................................... 33
Protect Worksheet Elements .................................................................................................. 33
Protect a Workbook from Viewing or Editing ......................................................................... 34
Lock or Unlock Specific Areas of a Protected Worksheet ....................................................... 34
Lock Only Specific Cells and Ranges in a Protected Worksheet.............................................. 34
DATA VALIDATION .............................................................................................................35
Enter Positive Integers (Negative Numbers Not Allowed) ...................................................... 35
Entering a Specific Number of Characters .............................................................................. 35

Office 2019: PowerPoint Excel, and Access iii


Entering Only the Current Date .............................................................................................. 36
Drop-down List ........................................................................................................................ 36
Accepting Text Only................................................................................................................. 36
Acceptance of Value Only if it is Greater Than the Value in the Previous Cell ....................... 36
Class Exercise 2: Data Validation ............................................................................................. 36
RENAMING A WORKSHEET .................................................................................................37
Using Office Ribbon ................................................................................................................. 37
Using Context Menu ................................................................................................................ 37
HEADERS AND FOOTERS .....................................................................................................37
FORMATTING SPREADSHEETS ............................................................................................37
Formatting Numbers ............................................................................................................... 38
Cell Borders ............................................................................................................................. 38
Apply Cell Borders ................................................................................................................... 38
Remove Cell Borders ............................................................................................................... 39
Cell Styles................................................................................................................................. 39
Class Exercise 3: Formatting .................................................................................................... 40
Class Exercise 4: General Formatting ...................................................................................... 41
WEEK 4: CELL REFERENCING ...................................................................................................43
OVERVIEW .........................................................................................................................43
CALCULATIONS ..................................................................................................................43
Simple Formula Calculations ................................................................................................... 43
Formula Bar ............................................................................................................................. 43
Using Cell Referencing............................................................................................................. 43
Using the Mouse for Cell Referencing..................................................................................... 44
Referencing Cells in Formulas ................................................................................................. 44
Class Exercise 1: Formulas ....................................................................................................... 44
Automatic Calculation ............................................................................................................. 45
Class Exercise 2 – Adding Several Numbers Together ............................................................ 45
CELL REFERENCING .............................................................................................................46
Create a Cell Reference on the Same Worksheet ................................................................... 46
Relative and Absolute Cell References.................................................................................... 46
Relative Cell Reference............................................................................................................ 46
Class Exercise 3: Relative Reference ....................................................................................... 48
Advantages of Relative Cell References .................................................................................. 48
Disadvantages of Relative Cell References ............................................................................. 48

Office 2019: PowerPoint Excel, and Access iv


Absolute Cell Reference .......................................................................................................... 48
Class Exercise 4: Absolute Reference ...................................................................................... 49
Class Exercise 5: Absolute Reference ...................................................................................... 50
Class Exercise 6: Absolute Reference ...................................................................................... 51
Advantages of Absolute Cell Reference .................................................................................. 51
Disadvantages of Absolute Cell Reference.............................................................................. 51
Mixed Cell Reference – (Relative Row Absolute Column) ...................................................... 52
Mixed Cell Reference (Absolute Row Relative Column Reference) ........................................ 52
Class Exercise 7: Mixed Cell Reference ................................................................................... 52
Mixed Reference (Absolute and Relative References)............................................................ 53
Class Exercise 8: Mixed Cell Reference ................................................................................... 53
External Cell Reference in Excel .............................................................................................. 53
How to Reference another Sheet in Excel .............................................................................. 54
Creating a Reference to Another Sheet in Excel ..................................................................... 54
Class Exercise 9 – Cell Reference............................................................................................. 55
HOW TO DEFINE AND EDIT A NAMED RANGE IN EXCEL .......................................................56
DEFINING AND MANAGING NAMES WITH THE NAME BOX .................................................56
Naming Rules and Restrictions................................................................................................ 56
Deleting Name Range(s) using Names Manager..................................................................... 56
Editing/Renaming Name Ranges using Names Manager ........................................................ 57
WEEK 5: USING FUNCTIONS AND FORMULAS TO CREATE AND INTERPRET DATA ...................58
OBJECTIVES ........................................................................................................................58
Functions ................................................................................................................................. 58
Class Exercise 1 – Adding Several Numbers Together ............................................................ 58
WORKING WITH ARGUMENTS ............................................................................................59
USING A FUNCTION ............................................................................................................60
Working with Unfamiliar Functions ....................................................................................60
UNDERSTANDING NESTED FUNCTIONS ...............................................................................61
Class Exercise 2 – SUM Function ............................................................................................. 61
Class Exercise 3 – Using the AutoSum Tool............................................................................. 62
Class Exercise 4 – Using Functions in a Table .......................................................................... 62
Excel Text Functions: LEFT, RIGHT, MID and LEN .................................................................... 63
Syntax for the ‘LEFT’ Function ................................................................................................. 63
Syntax for the ‘RIGHT’ Function .............................................................................................. 64
LEFT and RIGHT Functions in Use ............................................................................................ 64

Office 2019: PowerPoint Excel, and Access v


‘MID’ Function ......................................................................................................................... 65
FUNCTION: LEN (LENGTH) ..................................................................................................66
THINGS TO REMEMBER WHEN USING THE LEN FUNCTION IN EXCEL .................................... 66
Using Trim Function ................................................................................................................ 67
Using an IF Function ................................................................................................................ 67
Function Wizard ...................................................................................................................... 68
Class Exercise 5: Formulas and Functions ............................................................................... 68
COPYING A FORMULA ........................................................................................................69
Using the Fill Handle................................................................................................................ 69
Using Traditional Copy and Paste ........................................................................................... 69
ROUND FUNCTIONS ...........................................................................................................69
Class Exercise 6: Round Function ............................................................................................ 69
MROUND Function .................................................................................................................. 70
WEEK 6: ADVANCED EXCEL FUNCTIONS ..................................................................................71
COUNTIF FUNCTION ................................................................................................................ 71
Class Exercise 1: CountIF Function .......................................................................................... 71
COUNTIF Formulas with Wildcard Characters (Partial Match) ............................................... 72
COUNTIF for Blank and Non-Blank Cells ................................................................................. 72
COUNTIF not Blank .................................................................................................................. 72
COUNTIF Blank ........................................................................................................................ 72
COUNTIFS Function ................................................................................................................. 72
SUMIF Function ....................................................................................................................... 73
Class Exercise 2: SumIf Function ............................................................................................. 73
Class Exercise 3: SUMIFS Function ....................................................................................... 74
LOOKUP FUNCTIONS ..........................................................................................................74
VLOOKUP and HLOOKUP ....................................................................................................74
Class Exercise 4 – Vertical Lookup ........................................................................................... 75
DELETE A FORMULA ...........................................................................................................76
USE THE RANK AND PERCENTILE TOOL FROM THE ANALYSIS TOOLPAK ...............................76
The Analysis ToolPak ............................................................................................................... 76
Load the Analysis ToolPak ....................................................................................................... 76
Adding the Analysis ToolPak in Excel ...................................................................................... 77
Using the Rank and Percentile Tool in Excel ........................................................................... 77
MATCH FUNCTION .............................................................................................................78
INDEX FUNCTION ...............................................................................................................79

Office 2019: PowerPoint Excel, and Access vi


Class Exercise 5: Using IF Function .......................................................................................... 79
UNDERSTANDING EXCEL ERROR VALUES AND HOW TO FIX THEM.......................................80
WEEK 7: CHARTS AND GRAPHS ..............................................................................................81
OVERVIEW .........................................................................................................................81
OBJECTIVES ........................................................................................................................81
DATABASE COMMANDS .....................................................................................................81
DATA FORM .......................................................................................................................81
Class Exercise 1: Data Form ..................................................................................................... 82
Form AutoFill ........................................................................................................................... 82
Data Sort .................................................................................................................................. 82
Class Exercise 2: Sort and Filter ............................................................................................... 83
AutoFilter................................................................................................................................. 83
CHARTS ..............................................................................................................................83
Types of Graphs ....................................................................................................................... 83
Creating Column Chart ............................................................................................................ 85
CHART LAYOUT AND STYLE.................................................................................................85
Class Exercise 2: Chart ............................................................................................................. 86
MODIFYING A CHART .........................................................................................................86
Moving a Chart ........................................................................................................................ 86
Resizing a Chart ....................................................................................................................... 86
Changing a Feature/Properties ............................................................................................... 86
Deleting a Chart ....................................................................................................................... 87
Printing a Chart........................................................................................................................ 87
Class Exercise 3: Creating Charts ............................................................................................. 87
WEEK 8 CREATING SIMPLE DATABASE ....................................................................................89
OBJECTIVES ........................................................................................................................89
INTRODUCTION TO DATABASES .........................................................................................89
What is a Database? ................................................................................................................ 89
Relations - Restricted Set of Rules .......................................................................................... 89
Primary Key ............................................................................................................................. 90
Foreign Key .............................................................................................................................. 90
DATABASE USING MS ACCESS ............................................................................................90
Starting MS Access .................................................................................................................. 90
Creating a New Database ........................................................................................................ 90
Creating Tables/Relations ....................................................................................................... 92

Office 2019: PowerPoint Excel, and Access vii


Declaring a Primary Key .......................................................................................................... 93
Modifying Field Properties ...................................................................................................... 93
Class Exercise 1: Creating Tables ............................................................................................. 94
Saving a Table .......................................................................................................................... 97
Entering Data........................................................................................................................... 98
Class Exercise 2: Creating Tables ............................................................................................. 99
Class Exercise 3: Creating Tables ........................................................................................... 100
WORKING WITH CALCULATED FIELDS AND EXPRESSIONS ................................................. 104
Class Exercise: Calculated Field ............................................................................................. 105
WEEK 10: RELATIONSHIPS AND FORMS ................................................................................ 107
OBJECTIVES ...................................................................................................................... 107
RELATIONSHIPS................................................................................................................ 107
CREATING RELATIONSHIPS BETWEEN TABLES ................................................................... 107
Class Exercise 1: Relationship................................................................................................ 108
FORMS ............................................................................................................................. 109
Bound Forms ......................................................................................................................... 109
Unbound Forms ..................................................................................................................... 110
Types of Bound Forms ........................................................................................................... 110
Single Item Form ................................................................................................................... 110
Multiple Item Form ............................................................................................................... 110
Split Form .............................................................................................................................. 110
CREATING FORMS ............................................................................................................ 110
Multiple Items Form. ............................................................................................................. 113
Creating Split Form ................................................................................................................ 114
Creating a Form in Design View ............................................................................................ 114
Adding Records Using a Form ............................................................................................... 115
Editing Forms ......................................................................................................................... 115
WEEK 11: QUERIES AND REPORTS ........................................................................................ 117
OBJECTIVES ...................................................................................................................... 117
QUERIES........................................................................................................................... 117
TYPES OF QUERIES COVERED: ........................................................................................... 117
Select Queries........................................................................................................................ 117
Creating Select Query............................................................................................................ 118
To create a simple one-table query: ..................................................................................... 118
One Table Query with Criteria .............................................................................................. 119

Office 2019: PowerPoint Excel, and Access viii


Class Exercise 1: Query .......................................................................................................... 120
QUERY THAT USES MULTIPLE TABLES. .............................................................................. 120
Select Queries – Totals/Aggregating ..................................................................................... 121
Class Exercise 2: Query Aggregate ........................................................................................ 121
Hide a Total row .................................................................................................................... 122
Parameter Queries ................................................................................................................ 123
Creating Parameter Query .................................................................................................... 123
Update Queries ..................................................................................................................... 124
Creating Update Query ......................................................................................................... 124
Delete Query ......................................................................................................................... 125
Creating Delete Query ........................................................................................................... 125
REPORTS .......................................................................................................................... 125
Creating a Report Using Wizard ............................................................................................ 125
Creating a Report in Design View .......................................................................................... 127
Printing Reports..................................................................................................................... 127
COURSE OUTLINE .......................................................................... Error! Bookmark not defined.
ICT122 LECTURES AND PRACTICAL SESSIONS TIMETABLE ...................................................... 134

Office 2019: PowerPoint Excel, and Access ix


ICT LABORATORY RULES AND REGULATIONS
1. ENTER THE COMPUTER LAB QUIETLY AND WORK QUIETLY. THERE ARE OTHER GROUPS
AND INDIVIDUALS WHO MAY BE USING THE COMPUTER LAB. PLEASE BE RESPECTFUL.
2. PLEASE TREAT FELLOW USERS OF THE LABORATORY, AND ALL EQUIPMENT WITHIN THE
LABORATORY, WITH THE APPROPRIATE LEVEL OF CARE AND RESPECT.
3. NO FOOD, DRINK, OR USE OF TOBACCO IN ANY FORM IS ALLOWED IN THE LABS.
4. MUTE YOUR CELL PHONES!
5. THE USE OF MOBILE PHONES DURING PRACTICAL TESTS AND LABORATORY EXERCISES IS
PROHIBITED.
6. LAB USERS SHOULD MAINTAIN PROFESSIONAL AND COURTEOUS COMMUNICATION.
ELECTRONIC DEVICES SHOULD BE USED ON A PROFESSIONAL LEVEL. NO OBNOXIOUS OR
BELLIGERENT BEHAVIOR WILL BE TOLERATED.
7. PLEASE OPERATE THE EQUIPMENT WITH RESPECT AND CARE.
8. DO NOT MISBEHAVE IN THE COMPUTER LABORATORY. ACTIVITIES IN THE LAB THAT ARE
CONSIDERED BY THE ICT LECTURERS AND INSTRUCTORS TO BE ABUSIVE TO THE
SOFTWARE, HARDWARE MAY RESULT IN EXPULSION FROM THE LAB(S) AND REPORTED
TO THE DEAN/HOD.
9. DO NOT INSTALL ANY SOFTWARE ON YOUR OWN.
10. DO NOT COPY, MODIFY ANY SOFTWARE. DO NOT OVERWRITE THE OPERATING SYSTEM,
MODIFY ANY OTHER SYSTEM PARAMETERS AND DO NOT CHANGE COMPUTER SETTINGS
OR BACKGROUNDS. (UNLESS ADVISED TO DO SO)
11. FOR ANY HARDWARE, SOFTWARE AND LOG IN PROBLEMS, PLEASE CONTACT THE ICT
LECTURERS AND INSTRUCTORS.
12. USE OF ILLEGAL MATERIALS IN THE LABS IS GROUNDS FOR DENIAL OF USE OF THE LABS.
13. CLEAN UP YOUR WORK AREA BEFORE YOU LEAVE.
14. DO NOT REMOVE ANYTHING FROM THE COMPUTER LABORATORY WITHOUT
PERMISSION.
15. DO NOT TOUCH, CONNECT OR DISCONNECT ANY PLUG OR CABLE WITHOUT YOUR
LECTURER/LABORATORY TECHNICIAN’S PERMISSION.
16. STUDENTS SHOULD NOT ATTEMPT TO REPAIR, OPEN, TAMPER OR INTERFERE WITH ANY
OF THE COMPUTER IN THE LAB.
17. STUDENTS SHOULD BE AWARE OF CORRECT POSTURE WHEN USING COMPUTER
EQUIPMENT SEE PICTURE.
18. ANY FAILURE TO FOLLOW THESE LAB RULES MAY RESULT IN THE LOSS OF YOUR LAB
PRIVILEGES.
19. ALWAYS SANITIZE YOUR HANDS WHEN YOU CHANGE MACHINES OR ASSIST A FELLOW
STUDENT.

Office 2019: PowerPoint Excel, and Access x


Source: https://www.lornaroseosteopathy.com/top-10-desk-posture-tips/workstation-set-up-labelled/

Source: https://www.northernpodiatry.com.au/blog/2018/04/15/workplace-posture-and-the-effects-on-your-body/

Office 2019: PowerPoint Excel, and Access xi


WEEK 1/2: MICROSOFT POWERPOINT 2019
Learning how to use PowerPoint. PowerPoint is a system in the Microsoft 2019 Suite that enables
you to present information in office meetings, lectures, and seminars to create maximum impact
in a minimal amount of time.

PowerPoint presentations can amplify your message, accelerate the information being absorbed
and assist with comprehension enabling faster decision making.

OBJECTIVES

• Creating Slides
• Making Changes to Presentation
• Adding Images and Charts
• Adding Motion

INTRODUCTION

Here are some useful terms in PowerPoint that you must know:

Slide: An individual screen in a slide show.

Presentation File: The file you save that contains all the slides, speaker’s notes, handouts, etc, that
make up your presentation.

Object: Any element that appears on a PowerPoint slide, such as clip art, text, drawings, charts,
sounds, and video clips. You can refer to a clip art object, a text object, a title object, a drawing
object, etc. Anything you put on a PowerPoint Slide is called an object.

Slide Show: A series of slides displayed in sequence. A slide show can be controlled manually or
automatically.

Transition: A special effect used to introduce a slide during a slide show. For example, you can
fade in from black, or dissolve from one slide to another.

Office 2019: PowerPoint Excel, and Access 1


THE DESIGN RIBBON TOOLBAR

The Design Ribbon toolbar (Figure below) contains several categories for formatting the design
and elements of your presentation. These include Home, Insert, Design, Transitions, Animations,
Slide Show, Review and View. These icons are convenient but will not bring up dialogue boxes
that allow you to change the settings of these actions. You should use whichever method works
the best for you.

The Design Ribbon Toolbar

1. The Home tab – allows a user to edit Slides, Fonts, Paragraph, Drawing and Editing.
2. The Insert tab – allows a user to add Tables, Images, Illustrations, Links, WordArt, and Media
Clips.
3. The Design tab – allows a user to edit how the presentation will look. It includes features such
as Page Setup, Themes, and Background Styles.
4. The Transitions tab – allows a user edit Slide Transitions, Effects, and Transition Timing.
5. The Animations tab – allows a user to add custom animations to the presentation by choosing
from Preview, Animations, Advance Animation, and Animation timing.
6. The Slide Show tab – allows a user to select how the presentation will be displayed by choosing
Start your Slide Show, Set Up your Slide Show, and Adjust Monitor Settings.
7. The Review tab – allows a user to Proofread, Translate Languages, Comment Slides, and
Compare the presentation.
8. The View tab – allows a user to set the View of your Presentation, Create Master
Views,Show/Hide Features, Zoom, Switch from Color to Grayscale, Adjust Windows, and Add
Macros.

CREATING SLIDES

1. In the next step you will create a Title Slide for your presentation using a Blank Presentation
option. You will be working in Slide View.
2. Open the PowerPoint program. PowerPoint dialog box appears.

Office 2019: PowerPoint Excel, and Access 2


A good way to start any
presentation is with the title slide.

NB: If you are already working in


PowerPoint and want to create a
new blank presentation, follow
these steps:

1. Click on File, the choose New


2. In the New Presentation
dialog box, click Blank
Presentation under
Available Templates and Themes then choose Create.

Adding Text to a Slide

The Title Slide layout contains text


boxes for a title and a subtitle. Try
typing text in these boxes.

1. Click in the Title text box. A thick


gray border appears around the
text box indicating that it is
selected.
2. Type a title.
3. Click the Subtitle text box and type
a subtitle.

Adding another Slide

On the Slides Pane, right click where you want the new slide to be
located and choose New Slide

OR

On the Slides Pane, click where you want the new slide to be located
and then press Enter key.

OR

On the Slides Pane, click where you want the new slide to be located
and the in the Slides group under Home tab, click on New Slide button.

Office 2019: PowerPoint Excel, and Access 3


Moving from Slide to Slide

Let’s say you created several slides for your presentation. You’ve finished working on the last slide,
and now you want to take a look at your other slides. Here’s how you move from slide to slide in
Slide View.

To move to a previous slide click the upper double-arrow button on the lower right corner of
the PowerPoint window. The previous slide will appear.

You can also click on the slide you want. Or just use the up and down arrow keys to move up and
down your slides.

In Slide View, you can also move from slide to slide using the Page Up and Page Down keys on your
keyboard.

Outline View

In Outline View, your presentation appears as an outline,


made up of titles and main text from each slide. Because
you can see all your presentation in one window, rather
than one slide at a time, it’s an ideal place to plan,
organise, or edit your presentation.

Switching to Outline View

To switch to Outline View, Select the View Tab and click


on the Outline button (it is on the left under the
Presentation Views).

This is what you will see in the Outline View.

NB: When you right click on Outline pane, you will see a menu with useful tools for working in
this view

Adding a Slide in the Outline View

You can add a new slide in Outline View the same way you do in Slide View.

You can also add new slides quickly by using the Enter key. To add a new slide, right click after a
slide title and choose new slide.

OR

1. Place your cursor at the end of a slide title.


2. Press the Enter key. A new slide icon will appear in your outline.

Office 2019: PowerPoint Excel, and Access 4


Adding Text to the Outline View

If you want to add text to a slide that you created previously, place an insertion point in the outline
and start typing.

If you want to add text to a new slide you’ve created in Outline View, follow these steps:

1. Type a title beside the slide icon


2. After the slide title press Enter key. PowerPoint adds a new slide
3. Right click on the Slides pane, and click the demote button to convert the new slide to a
text object

This button will change a new slide to a simple line of text.

4. Type your text


5. To add another bullet point, press Enter.
NB: With the exception of the title slide, any text you add will be formatted as a slide.

Moving around in Outline View

When you are in Outline View, you will see all the text that appears on your slides. However,
PowerPoint lets you collapse the view, so you see only the outline titles. Use this option if you
want to print an outline of your presentation, or if you want to check the logical flow of your slides
without the distraction of extra text.

To collapse all the slides in your outline:

1. Right click on the Slides pane, and choose the Collapse All button. The slide text for all the
slides will disappear.

Use this button to hide extra text

To expand all of the slide tittles again:

1. Right click on the Slides pane, and choose the Expand All button. The text for all the slides
will appear again.
This button makes the hidden text appear again.

Other than the View tab of the Ribbon, you can also access most of these views by clicking the

four small buttons towards the right side of the Status Bar.

Office 2019: PowerPoint Excel, and Access 5


Moving from One Slide to the Next Slide

To move from one slide to another in Outline View, click anywhere on the slide you want to move
to. You can also move from slide to slide using the up and down arrow keys on your keyboard.

WHAT IS A TEMPLATE/DESIGN?

The default slide design for PowerPoint documents is a blank slide. Therefore, if you want your
slides to have a specific design, you must add one. A template is also called a presentation design;
it lets you create a presentation without worrying about design elements.

The template defines the colour, background, and font of the slides. PowerPoint has many
templates, which you can preview and select in the New Presentation dialog box. You can also use
the Design tab from the User Ribbon, and then To change the theme of your presentation, click
on the theme that you like and it will automatically apply to your slide.

PowerPoint also lets you customise the template. For instance, you can change the background
colour or typeface of a template.

Creating a Presentation Using Templates

1. Click the Design tab from the Ribbon.


2. Click the theme you want. The design will appear.

Making Changes to Presentation

If you don’t like where a text box is positioned on a page, you can move it to a new location. First
you select it, and then you move it.
1. Click the text box you want to move. A thick gray border will appear around the text box.
2. Place the pointer on the border. The pointer will change into a four-headed arrow.
3. Hold down the mouse button and drag the box to the new location.
4. Release the mouse button.

Resizing a Text Box

The gray border that appears around an object when you select it has square handles on its corners
and on its sides. These are called selection or resizing handles. You can click and drag these handles
to resize text boxes.

1. Click the text box to select it. A gray border will appear around the text box.
2. Place the pointer on a resizing handle. The pointer will change into a two-headed arrow.
3. Hold down the mouse button and drag the resizing handle until the box is the size you
want. Drag outwards to make the box larger. Drag inwards to make the box smaller.

Office 2019: PowerPoint Excel, and Access 6


NB: You can also resize the box so the height and width change at the same time. Simply click
on a corner resizing handle, and press the SHIFT key on your keyboard as you drag your
mouse.

Adding a New Text Box

Sometimes you may want to add text to a slide without using a built-in text box. For example, you
may want to type a label for a drawing, or you may want to add text to a blank slide layout. In
PowerPoint, you can add your own text boxes to any slide using the Text Box tool.

1. On the Text menu from Insert tab, click the Text Box button. The pointer will change to a cross.

This button creates a text box.

2. Click on the slide where you want to place the text. A small text box will appear.
3. Type a word in the text box. As you type, the box will expand to fit the text.

The text box will grow to fit the text

4. After you finish typing, click outside the text box. The border around the box will disappear.

Deleting a Text Box

You can delete your text boxes using the Delete key on your keyboard.
1. Click the text box to select it. A gray border will appear around the text box.
2. Click the box’s border. The insertion point will disappear from the text box.
3. Press the Delete key on the keyboard. The text and the border both disappear. The entire
text box is deleted.
If you want to delete a built-in text box (one that came with the original slide), you need to add
one additional step.

1. Click the text box to select it.


2. Click the box’s border and then press the Delete key. The text disappears, but the border
remains.
3. Click the border again and press the Delete key. The entire box is deleted.

Outlining a Text Box

Office 2019: PowerPoint Excel, and Access 7


The thick gray border that appears around a text box is temporary
and disappears when the text is deselected. If you want a
permanent outline around your text box, create one using the
Drawing menu under the Home tab.

Try adding a blue dotted outline to a text box.

1. Click the text box to select it. A border will appear around
the text box.
2. Select Shape Format in the tab, then click the Shape Styles
launcher and from the Format Shape dialog box choose Line
Color button, then choose the Solid line.
3. Choose any colour of your choice.
4. Try to see what the Line Style button and nay of the
available fills.
5. Select outside the text box to deselect it.

Changing Font

1. Click the text box to select it.


2. Place the pointer on the box’s border and
click again. The insertion point disappears,
indicating that the text box is selected.
3. Click the Font launcher under the Home tab.
The Font dialog box appears.
4. In the Font style list, click Bold; in the Size list
click 36; and in the Font color list, click green.
5. Click OK to close the dialog box. All the text
in your text box is now green, bolded, and a
font size of 36.

Selecting a New Bullet Style

1. Click anywhere in the bulleted text to select it.

Office 2019: PowerPoint Excel, and Access 8


2. In the Paragraph group, under the Home tab,
click on arrow next to bullets, and choose
Bullets and Numbering. The Bullet and
Numbering Dialog box will appear and click on
the bullet style you prefer.
3. If you want, select a new colour for the bullet
in the Color list box.
4. Click OK. The new bullet style will appear in
your bullet text.

Changing Background Colour

In PowerPoint it’s easy to change the background colour of the slide you are working on. Let us
say you want to change the colour of the slide to light blue. Here is what to do:

1. In the Customize group under the Design tab, click on Format Background. The Format
Background dialog box will appear.
2. Choose Solid fill on the right pane.
3. Click on the Color list box and choose any colour of your choice. If the colour you want is
not shown, click on More Colors to open the Colors dialog box and choose the colour you
want.
4. If you like what you see, click the Close button. The background colour of the slide is now
light blue.
5. If you want the background colour to apply for all the slides, click the Apply to All button.

ADDING IMAGES AND CHARTS

This will show you how to add shapes, images and charts to a presentation. Get ready for some
“zing”!

Adding a Shape

PowerPoint lets you add a variety of shapes to the slides of your presentation.
Try adding a start shape to your slide, using the AutoShape tool on the Drawing
group.

1. Click on the 5-point star shape, in the Drawing group under Home
tab. The pointer will change into a cross.

2. Click anywhere on the slide. A star of predefined size will be


inserted.

Office 2019: PowerPoint Excel, and Access 9


The star looks huge, but don’t worry – you can resize it
3. To make the shape larger (or smaller), drag a resizing handle. To resize the shape
proportionally, drag from the corners.
4. Another way is through the Insert Tab, try it and see what will happen.

Moving a Shape

Let us try moving a star to another part of the slide.

1. Place the pointer on the star. The pointer turns into a four-headed arrow.
2. Click and hold down the mouse button, then drag the star to the new location.
3. When the star is positioned where you want it, release the mouse button.

Adding Colour and Texture to a Shape

First, try adding the colour yellow to the star.

1. Click the star shape to select it.


2. Click the arrow beside the Shape Fill button, in the Drawing group under Home tab and
then click More Fill Colors. A Colors dialog box appears.
3. Click the Standard tab, then under Colors, click a shade of yellow.
4. Click OK to close the Colors dialog box. The star is now yellow.

Next, try adding some texture to the shape.

1. Click the star to select it.


2. Click the arrow beside the Shape Fill
button, in the Drawing group under
Home tab and then click the Texture tab.
3. Click on a texture, and then click OK.

Some of the images are pictures (remember Clip


Arts??? You know how to do that, we did it last semester…..Insert tab, then Clip Art under Images
group). You can also add your own works of art as we did it in ICT121. Go to Insert tab, choose
Picture under the Images group and in the Insert Picture dialog box that appears choose your art
of work where you saved it.

Class Exercise:

Insert a screenshot/picture from the web and try to change the background colour etc.

Office 2019: PowerPoint Excel, and Access 10


Layering images

Sometimes you may end up with images overlapping each other on a slide. Let
us say you’ve created a design where three different coloured squares are
layered on top of each other: a blue square at the back, a yellow square in the
middle, and an orange square in front.

You want to send the orange square to the back layer. How do
you get it there?

Try these steps:

1. Click on the orange square to select it


2. Click the arrow beside the Arrange button, in the
Drawing group under Home tab and then click Send to
Back under Order Objects submenu.

Adding shadows to images

Let’s try adding a shadow to a shape.

1. Click on the shape to select it


2. Click the arrow beside the Shape Effects button, in the
Drawing group under Home tab and then click Shadow
in the submenu that appears.
3. Click a shadow style you want.

Adding a chart

Charts are used to create diagrams in MS PowerPoint. To add a chart to any slide, click the Chart
button in the Illustrations group under Insert tab.

When you insert a chart, a sample data sheet and corresponding bar chart will appear on your
slide. PowerPoint has included some sample data in the first four columns. The bars in a chart are
graphical representation of the numbers in the data sheet. Notice how a higher number in the
data sheet results in a taller corresponding bar.

To create your own chart, you can replace the data in the sample data sheet with your own. Try
adding a number to the chart to see how it changes the corresponding bar on the chart.

Office 2019: PowerPoint Excel, and Access 11


NB: You can use predefined chart layouts you can use these by click the Design Ribbon > Insert >
Chart. Once the Chart button is expanded, you will have several options to choose from, such as
Column, Line, Pie, etc. These are found in the Design group under Chart Tools. Remember: you
have to select the chart to get Chart Tools.

After you’ve finished entering the data, exit the work window by closing the data sheet. If you
need to make any revisions to the chart data, right click on the Chart and choose Edit data (or click
on Edit data button in the Data group under Design).

NB: To do other modifications to the chart, you use Chart Tools.

Adding a table

You can add a table to a slide using the Insert tab. Let us try adding a table to your slide.

1. Click on the Table arrow in the Tables group under Insert tab.
2. In the drop-down box, click and drag the pointer across the number of rows and columns
you want for your table. For example, three rows and three columns.
3. Release the mouse button. The table work window will appear. The work window is where
you enter and edit information, and where you format the table.

ADDING MOTION

Switching to Slide Sorter View

When you go to Slide Sorter View, you see miniatures of all the slides in the presentation,
complete with text and graphics. This view is useful for rearranging slides, and for adding
transitions to slides.

There are two ways to switch to Slide Sorter View:

1. Click the Slide Sorter View button in the lower left corner of the PowerPoint window.
2. Click the View tab and choose Slide Sorter under Presentation Views group.

Moving Slides Around

The Slide Sorter View is the easiest place to rearrange the order of your slides.

Let us say you have four slides in your presentation, and you decide that Slide 2 should really
appear after Slide 3. Here is what you do to move the slides around:

Office 2019: PowerPoint Excel, and Access 12


1. Click Slide 2 and hold down the mouse button. A small gray rectangle appears on the
pointer.
2. Drag the pointer to the slide’s new position after Slide 3. A vertical line should appear after
Slide 3.
3. Release the mouse button. Slide 2 should now be positioned after Slide 3.

Adding a Transition

A transition is a special effect used to introduce a slide during a slide show.


The following steps will show you how to add a transition to a slide.

1. Select the Slide Sorter in the View tab and click the slide you want to add the transition to.
2. Click the Transitions tab, and then under the Transition to This Slide group choose the
transition style you like. There are more transitions selection by clicking the arrow pointing
down.
3. In the Effects Options list box, choose the direction you prefer.
4. Under the Timing group, you can choose the sound that will play during the transition
between the previous slide and the current slide, how long a transmission should take and
whether you time your slides or move them through the click of the mouse.

NB: You can preview the transition effect you applied by clicking on Preview in the Preview group
still in the Transitions tab. If you want the same transition to apply to all the slides in your
presentation, click the Apply to All button in the Timing group.

Timing a Transition

If you want you slide show to run automatically, you must add timing to slides. When you add
timing to a slide, you specify the number of seconds to remain on each slide.

Here is how you add timing to your slides:

1. Select the slide you want to add timing to by clicking it.

2. Click the Transition tab, and then under Advance Slide in the Timing group uncheck the box
next to On Mouse Click and check the box before After.
3. In the seconds’ box, type the number of seconds to remain on the slide. For example, 5
seconds.

When you run your slide show, the slide that you applied the timing to will only remain on the
screen for five minutes.

Office 2019: PowerPoint Excel, and Access 13


Adding Animation to an Object

When you animate an object, you add special visual or sound effects to it.

The following will show you how to animate an object:

1. Click on the object you want to animate, e.g., the title of your presentation, to select it.
2. Click on the Animation tab, and then under Animation group choose the animation style
you like, e.g., Split.

Class Exercise:

Try Special Effects under Animation and see how they work. Also, try stuff that is under Advanced
Animation and Timing groups.

Creating Speaker Notes

When you give your presentation, you may need to refer to notes to elaborate on a slide’s
material, or to remind you to mention some detail. In PowerPoint, you can write your speaker’s
notes while you work on your slides. Simply write your notes for the slide in the text box provided.
Once you’ve written these notes, they can only be seen in the Note Page View. They will not be
displayed during the Slide Show.

Follow these steps to create speaker’s notes:


1. In the Normal View, display the slide you want to create notes for.
2. Click the View tab, and then click Notes Page in the Presentation Views group.
3. Adjust the Zoom to 100 % on the Zoom handle at the bottom right of the slide window. This
will make your text easier to see.
4. Click in the box and type your notes.

NB: In Normal View, you can also write your notes in the Notes window at the bottom of a slide.

Timing the Presentation

When you select Rehearse Timings, your Slide Show starts running, and PowerPoint will start
timing it. The timing is displayed in the Rehearsal dialog box. When the Slide Show comes to an
end, PowerPoint will give you the final running time.

Follow these steps to time your presentation:

Office 2019: PowerPoint Excel, and Access 14


1. Click the Slide Show tab, and then click Rehearse Timings in the Set Up group. The Slide Show
begins and a Rehearsal dialog appears in the upper-right-hand corner of the screen.
2. Begin speaking and presenting your show.
3. If you want to repeat your rehearsal of a slide, click the Repeat button on the Rehearsal dialog
box. The current slide repeats and the timing for it starts over.
4. Rehearse your presentation until it is finished. After you are done, a message box appears. It
tells you the final running time and it asks you if you want to record the timing to use for
viewing the presentation.
5. Click No. You are returned to the PowerPoint window.

NB: You Click No because you are only timing the show. You would click Yes if you wanted to use
the recorded timings to automate your presentation.

PRINTING SLIDES

This can only be done when a printer is connected. Try to do this at your own time.

To print your slides, click on the File tab on Design toolbar, then the Print command.

1. When you select the Print command, you will notice all of your printing options including a
preview of your document are right at your fingertips.
2. Select your Print options and click on the Print command.

Print Preview

When you select the Print command under the File tab, your document will automatically appear
in as a preview of what will print. If you change your print options, the preview will change
accordingly. To view each page, click on the left or right arrows next to the page number in the
box and the bottom middle section of your screen.
Print Layout

You can select how you would like your slides to be printed by selecting the drop-down arrow next
to the Fill Page Slides command.

Then, click on the format would like your slides to print in. The different options are:

Office 2019: PowerPoint Excel, and Access 15


a) Full Page Slides – print out with each slide
on a full page.
b) Handouts - print out with up nine slides
per page.
c) Notes Page - print out of one slide per
page including any notes you may have
added in the
d) Notes Pane while creating your
presentation.
e) Outline View - print out of your text from
all of your slides in an outline format.

Once you select your printing format, a preview of your slides will appear. When you are ready to
print, click the Print command.

NOTE: If you would like to print slides that also include lines for audience notes you need to select
Handouts (3 Slides Per Page).

Office 2019: PowerPoint Excel, and Access 16


WEEK 2/3: CREATING, ORGANISING AND
FORMATTING AN MICROSOFT EXCEL WORKBOOK
2019

OBJECTIVES

• Spreadsheet Editing

➢ Entering Data
➢ Moving Cell Contents
➢ Inserting Rows and Columns
➢ Deleting Rows and Columns
➢ Moving Cells

• Excel 2019 Ribbon


• Controlling Workbooks and Worksheets
➢ Find, Replace, Go To
➢ Hide and Unhide Rows and Columns
➢ Hide and Unhide a Worksheet
➢ Hide and Unhide a Workbook
➢ Split a Worksheet
➢ Freeze and Split Panes
➢ Merge or Split Cells
➢ Passwords Protect a Worksheet or a Workbook.
✓ Protect Worksheet Elements from all Users
✓ Protect Workbook Elements
✓ Protect a Workbook File from Viewing or Editing.
➢ Data Validation
➢ Renaming a Worksheet
➢ Inserting a Header/Footer
➢ Formatting
✓ Format Numbers
✓ Cell Borders
✓ Cell Styles

INTRODUCTION

Excel is a member of the spreadsheet family of software. Excel can be used to create and format
workbooks (a collection of spreadsheets) to analyse data and make more informed business
decisions.

Office 2019: PowerPoint Excel, and Access 17


Spreadsheet is a large sheet of paper with columns and rows. A spreadsheet consists of a grid of
cells into which text, numbers, and formulae may be placed. A cell can contain a maximum of
32,767 characters.

STARTING THE PROGRAM

Click the Start button, and select Excel, then click Blank workbook. The program window opens
with a new blank workbook. The default new workbook in Excel has one worksheet, you can add
more worksheets or delete existing worksheets as needed.

EXPLORING THE USER INTERFACE: EXCEL PROGRAM WINDOW

The Excel program window is easy to navigate and simple to use for the main elements of the
program window. It is designed to help you quickly find the commands that you need to
complete a task.

Office 2019: PowerPoint Excel, and Access 18


The Excel worksheet for Microsoft Office 2019 consists of a series of columns and rows. A
workbook is a collection of worksheets and is the actual Excel document or spreadsheet file.
The columns
are labelled A, B, C, … and the rows are labelled 1, 2, 3, …… the actual spreadsheet is much
larger than what can be displayed on screen at any one time.

Excel consists of 16 384 columns and 1 048 576 rows. Each spreadsheet location where data is
entered is called a cell. A cell is identified as the intersection of a column and a row. A1 refers
to the cell located at the intersection of column A and row 1.

EXCEL PROGRAM WINDOW ELEMENTS

Element Description
Title Bar Displays the name of the workbook and the program.
Minimize, Restore Used to control the program window. Use the Minimize button
Down/Maximize, and to hide the window. Use the Restore Down/Maximize button to
Close buttons adjust the size of the window. Use the Close button to exit Excel.

Contains frequently used commands that are independent of the


Quick Access toolbar
tab displayed on the Ribbon.
Contains all the commands related to managing workbooks and
Ribbon
working with workbook content.
Displays the data or formula stored in the active cell. It can also
Formula bar
be used to enter or edit a formula, a function, or data in a cell.
Displays the active cell address or the name of the selected cell,
Name box
range, or object.

Office 2019: PowerPoint Excel, and Access 19


Workbook window Displays a portion of the worksheet.
Each tab represents a different worksheet in the workbook. A
Sheet tabs workbook can have any number of sheets, and each sheet has its
name displayed on its tab.
Scroll tabs Used to scroll through the worksheet.
Displays various messages as well as the status of the Num Lock,
Status bar
Caps Lock, and Scroll Lock keys on the keyboard.
Used to display the worksheet in a variety of views, each suited
View Shortcuts toolbar
to a specific purpose.
Zoom Level button and Used to change the magnification of the worksheet.
Zoom slider

EXCEL RIBBON

The Ribbon contains multiple tabs, each with several groups of commands. You can add your own
tabs that contain your favorite commands. Certain programs, such as Adobe Acrobat Reader, may
install additional tabs to the ribbon. These tabs are called Add-ins.

To Customize the Ribbon

You can customize the Ribbon by creating your own tabs with whichever commands you want.
Commands are always housed within a group, and you can create as many groups as you want to
keep your tab organized. If you want, you can even add commands to any of the default tabs, if
you create a custom group in the tab.

Right-click the Ribbon and select Customize the Ribbon... from the drop-down menu.

1. Click New Tab. A new tab will be created with a new group inside it.
2. Make sure the new group is selected.
3. Select a command from the list on the left, then click Add. You can also drag commands
directly into a group.
4. When you are done adding commands, click OK.

If you do not see the command you want, click on the Choose commands drop-down box and
select All Commands.

Office 2019: PowerPoint Excel, and Access P a g e | 20


To Minimize and Maximize the Ribbon:

The Ribbon is designed to be responsive to your current task and easy to use, but if you find it is
taking up too much of your screen space, you can minimize it.

1. Click the arrow in the upper-right corner of the Ribbon to minimize it.
2. Select the desired minimizing option from the drop-down menu: Auto-hide Ribbon: Auto-hide
displays your workbook in full-screen mode and completely hides the Ribbon. To show the
Ribbon, click the Expand Ribbon command at the top of screen.
3. Show Tabs: This option hides all command groups when they are not in use, but tabs will
remain visible. To show the Ribbon, simply click a tab.
4. Create a folder on the desktop and call it Practical 2.
5. Open the Practical 2 folder and create an Excel file named Practical 2 – Exercise

TO OPEN AN EXISTING WORKBOOK

(Open the workbook used created in Step 5 – Practical 2)

1. Click the File tab. This takes you to Backstage view.


2. Select Open, then select This PC or alternatively, you can choose OneDrive to open files
stored on your OneDrive.
3. Go to location where the Excel file is saved, in this case select Desktop.
4. Select the file in the folder and if you have opened the existing workbook recently, it may
be easier to Select check the file under Recent Workbooks.

Opening a Workbook/File

Frequently Used Shortcuts


Practise using the following shortcuts. This table lists the most frequently used shortcuts in Excel.

To do this Press
Close a workbook Ctrl+W

Office 2019: PowerPoint Excel, and Access P a g e | 21


To do this Press
Open a workbook Ctrl+O
Go to the Home tab Alt+H
Save a workbook Ctrl+S
Copy Ctrl+C
Paste Ctrl+V
Undo Ctrl+Z
Remove cell contents Delete
Choose a fill colour Alt+H
Cut Ctrl+X
Go to Insert tab Alt+N
Bold Ctrl+B
Center align cell contents Alt+H,A,C
Go to Page Layout tab Alt+P
Go to Data tab Alt+A
Go to View tab Alt+W
Open context menu Shift+F10, or Context key
Add borders Alt+H, B
Delete column Alt+H, D, C
Go to Formula tab Alt+M
Hide the selected rows Ctrl+9
Hide the selected columns Ctrl+0

COMPATIBILITY MODE

Sometimes, you may need to work with workbooks that were created in earlier versions of
Microsoft Excel, such as Excel 2003 or Excel 2000. When you open these kinds of workbooks, they
will appear in Compatibility mode. Compatibility mode disables certain features, so you will only
be able to access commands found in the program used to create the workbook. For example, if
you open a workbook created in Excel 2003, you can only use tabs and commands found in Excel
2003.

Office 2019: PowerPoint Excel, and Access P a g e | 22


In the image below, the workbook has opened in Compatibility mode. You can see that the
sparklines and slicers features have been disabled.

Disabled commands in Compatibility mode

To exit Compatibility mode, you will need to convert the workbook to the current version type.
However, if you are collaborating with others who only have access to an earlier version of Excel,
it's best to leave the workbook in Compatibility mode so that the format will not change.

To Convert a Workbook:

If you want access all the Excel features, you can convert the workbook to the current Excel file
format.

Note that converting a file may cause some changes to the original layout of the workbook.

1. Download a workbook called Sales Data from ICT122 Eduhub Page, Week 3 into the
Practical 2 folder and put it in the folder you created in desktop.
2. Open the file you copied in step 1.
3. Click the File tab to access Backstage view and select Info and Click Check for Issues.
4. Select Check Combability command and select Excel 2016 and 2019 only
5. Deselect Check Combability and Click OK when saving this workbook
6. Then Click Save, the dialog box will appear. Select the location where you wish to save the
workbook, enter a file name for the presentation, and click Save.
7. The workbook will be converted to the newest file type.
8. Close the workbook.

ENTERING DATA

Entering Text

You can insert text in a worksheet to serve as labels for values, heading for columns or instructions
about the worksheet. Text automatically aligns to the left in a cell.

Entering Numbers
Numeric entries contain only numbers and are automatically aligned to the right in a cell. If you
precede a number with a minus sign or enclose it in parentheses Excel considers it to be a negative
number.

Office 2019: PowerPoint Excel, and Access P a g e | 23


OPENING A NEW WORKBOOK

1. Open new workbook


2. Click the cell to which you want to add data, making it the active cell.
3. Type some data in the cell, as you type, the data also appears in the formula tab.
4. When you finish typing press Enter. Excel makes the cell immediately below it the active cell.
5. Type some data into different cells as below. Press the arrow keys to move to the next cell.
(e.g. enter some row headers and column headers).

Excel Worksheet

Note: IF you enter text that is longer than column’s current width, the excess characters will
appear in the next cell to the right, if the cell is empty. If the adjacent cell is not empty the

Modify Column Width

1. Position your mouse over the column line in the column heading so that the white cross
becomes a double arrow .
2. Click and drag the column to the right to increase the column width or to the left to
decrease the column width.
3. Release the mouse. The column width will be changed in your spreadsheet.

Modify the Row Height

1. Position the cursor over the row line so that the white cross becomes a double arrow
. Positioning the mouse over the row line
2. Click and drag the row downward to increase the row height or upward decrease the row
height. Increasing the row height
3. Release the mouse. The height of each selected row will be changed in your worksheet.
Increased row height

Office 2019: PowerPoint Excel, and Access P a g e | 24


Set Column Width with a Specific Measurement

1. Select the columns you want to modify.


2. Click the Format command on the Home tab. The format
drop-down menu appears.
3. Select Column Width.
4. The Column Width dialog box appears. Enter a specific
measurement.
5. Click OK. The width of each selected column will be changed
in your worksheet.

6. Select AutoFit Column Width from the format drop-down


menu, and Excel will automatically adjust each selected
column so that all the text will fit.

WORKING WITH COLUMNS AND ROWS

Although the number of rows and columns in a worksheet is fixed, you can still insert rows and
columns if you need to make room for additional data or delete rows and columns if the data they
contain is no longer needed.

NOTE: these operations do not change the total number of rows and columns. The Cell group on
the Home tab contains commands that can be used to easily insert, delete, or format rows and
columns.

Cells Group on the Home Tab

Selecting Rows and Columns

You must select rows and columns to perform operations, such as applying the same format to
the entire row or column, changing the height of more than one row or the width of more than
one column at a time, and inserting or deleting rows and columns. When a row or column is
selected, every cell in the row or column is highlighted, except for the active cell.

Select a Single Row or Column

Click the row or column header.

Office 2019: PowerPoint Excel, and Access P a g e | 25


▪ To highlight rows: Shift+Space. Arrows Up or Down for additional rows.
▪ To select columns: Ctrl+Space. Arrows Left or Right for additional columns.
▪ To highlight every cell in the sheet: Ctrl+A

Select Multiple Adjacent Rows or Columns

Drag across the row or column headers. Or click the header of the first row or column you want
to select, hold down the Shift key, and then click the header of the last row or column you want
to select.

Select Multiple Non-Adjacent Rows or Columns

Hold down the Ctrl key, and then click the headers of the rows and columns you want to select.

Adjacent Range of Cells Non–Adjacent Range of cells


Inserting Rows and Columns

You can insert rows and columns into an existing worksheet to add additional data. Rows are
added above the current or select row.

1. Select any cell in the row that you want to insert a row above,
2. On the Home tab,
3. In the Cells menu, select Insert
4. Select Insert Sheet Rows

Inserting Columns

Columns are added to the left of the current column.

1. Select any cell in the column that you want to insert a column on its left,
2. On the Home tab,
3. In the Cells menu, Select Insert

Office 2019: PowerPoint Excel, and Access P a g e | 26


4. Then select Insert Sheet Columns

NOTE: If you select multiple rows or columns, Excel insets the same number of rows and columns
into the worksheet.

Deleting Rows and Columns

You can easily delete unwanted rows and columns from a worksheet. Before deleting a row or
column, you should make sure it does not contain data that you want to keep.

1. Click on a cell in the column or row you want to delete,


2. On to Home tab, in the Cells menu, select Delete option,
3. Select either to Delete Sheet Rows or Delete Sheet Columns.

NOTE: You can also right-click the row header and select Delete

FILL HANDLE

The fill handle is a small black dot or square in the bottom right corner of the active cell. The fill
handle can be used either to copy a cell’s contents to adjacent cells or to create a series. If Excel
recognizes the cell contents as part of a series, it will Auto Fill other selected cells with the next
items in the series. Use the fill handle by clicking on it with the mouse pointer to drag select
adjacent cells.

1. Select the cell or cells containing the content you want to use. You can fill cell content either
vertically or horizontally.
2. Position your mouse over the fill handle so that the white cross becomes a black cross
3. Click and drag the fill handle until all the cells you want to fill are highlighted.
4. Release the mouse, and your cells will be filled.
For example, if you need to continue a sequence, just enter the first two values into the starting
cell and grab the fill handle to copy the data across the specified range.

Note: a,b,c will repeat. It wouldn’t go to d,e f, etc.

Challenge: Try to make a,b,c to continue to d,e,f,etc

Office 2019: PowerPoint Excel, and Access P a g e | 27


TO CREATE A CUSTOM LIST DO THIS ; Select File, Options, Advanced, and Select
Custom List

Filled cells

You can also auto-populate any arithmetic


progression sequence where the difference
between numbers is constant.

Moving Cell Contents

1. Activate the cell you wish to move


2. Position your pointer on a border of the cell until the pointer turns into a white arrow
3. Hold down the left mouse button and drag the pointer to the new cell
4. Release the mouse button, and the contents will appear in the new cell
5. To copy a group of cells (non-adjacent), hold down the Control key (Ctrl) as you drag.

Inserting Rows and Columns

Rows are added above the current row.

1. Select any cell in the row that you want to insert a row above,
2. On the Home tab,
3. In the Cells menu, Select Insert.
4. The Select Insert Sheet Rows

Inserting Columns

Note: Columns are added to the left of the current column.

1. Select any cell in the column that you want to insert a column on its left,
2. On the Home tab,
3. In the Cells menu, Select Insert.
4. The choose Insert Sheet Columns

Deleting Rows and Columns

Note: Excel deletes the current column or row

1. Click on a cell in the column or row you want to delete,

Office 2019: PowerPoint Excel, and Access P a g e | 28


2. Go to Home tab,
3. In the Cells menu, select Delete option,
4. Select to Delete Sheet Rows or Delete Sheet Columns.
5. Save and close the file.

CONTROLLING SPREADSHEETS

Find, Replace, Go To

Excel can search a spreadsheet and find specific entries, it can also replace those entries it finds
with something else. In a large worksheet you can locate specific items (labels, values) or cell
references by using the Find Command.

1. Under Home tab, on the Editing menu, choose Find & Select.
2. From the menu that appears choose Find.
3. Type whatever you want to find in the provided box.
4. Click OK.

To change data values or formulae you can use the Replace Command.

1. Under Home tab, on the Editing menu, choose Find & Select.
2. From the menu that appears choose Replace.
3. Type in whatever you want to modify together with its replacement in the appropriate boxes.
4. Click OK.
5. To jump to any cell on the worksheet you use the Go To command.

1. Under Home tab, on the Editing menu, choose Find & Select.
2. From the menu that appears choose Go To.
3. Type in the desired cell address in the Reference box.
4. Click OK.

Using the keyboard:

Press “Ctrl” and “F” on the keyboard at the same time, the
pop up menu for the find and replace tool will appear.

Class Exercise 1: Find, Replace, Go To

1. Using the Sales Data1 file downloaded from the ICT122 Eduhub Page, do the following:

i. Find and Replace, replace the word “Rail Park” with “Lobatse”
ii. Find and replace the word “broudhurst” with “Broadhurst”
iii. Find and replace the “gwest” with “Gwest”
iv. Go To December Sales
v. Go To July Sales

Office 2019: PowerPoint Excel, and Access P a g e | 29


MAKE SURE YOU HAVE COMPLETED THE ABOVE CLASS EXERCISE 1 AND
IT HAS BEEN CHECKED BY THE INSTRUCTOR BEFORE MOVING TO THE
NEXT PART OF THE LAB.
Hide and Unhide Rows or Columns

To Hide

1. Select the row(s) or column(s) you want to hide.


2. Under Home tab, on the Cells menu, choose Format.
3. From the resultant menu choose Hide & Unhide under Visibility.
4. Then choose either Hide Rows or Hide Columns, depending on what you want to hide.

To Unhide

1. Select the two rows or columns that border the hidden row(s) or column(s).
2. Under Home tab, on the Cells menu, choose Format.
3. From the resultant menu choose Hide & Unhide under Visibility.
4. Then choose either Unhide Rows or Unhide Columns, depending on what you want to unhide.

Hide and Unhide a Worksheet

To Hide

1. Activate the worksheet you want to hide.


2. Under Home tab, on the Cells menu, choose Format.
3. From the resultant menu choose Hide & Unhide under Visibility.
4. Then choose Hide Sheet.

To Unhide

1. Under Home tab, on the Cells menu, choose Format.


2. From the resultant menu choose Hide & Unhide under Visibility.
3. Then choose Unhide Sheet
4. Choose the worksheet you want to unhide from the dialog box that appears
5. Click OK.

Note: Although you can hide multiple sheets at once, you can only unhide one sheet at a time.

Hide and Unhide a Workbook. To Unhide

To Hide On the View tab choose Unhide.


Splitting a Worksheet into Two Parts.
1. Open the workbook you want to hide.
2. On the View tab choose Hide. 1. Select the row or column where you want
the split to occur.

Office 2019: PowerPoint Excel, and Access P a g e | 30


2. On the View tab choose Split. Go to View tab choose Split.

Remove the Split

Merge or Split Cells

When you merge two or more adjacent horizontal or vertical cells the cells become one larger cell
that is displayed across multiple columns or rows. When you merge multiple cells, the contents of
only one cell appear in the merged cell. This is very useful especially when making heading for
tables,.

Merge and Center Cells

1. Select two or more adjacent cells that you want to merge.


2. On the Home tab, in the Alignment group, click Merge and
Center.
3. The cells will be merged in a row or column, and the cell
contents will be centered in the merged cell.

Merge Cells

To merge cells only, click the arrow next to Merge and Center, and then click Merge Across or
Merge Cells.

Note: If both cells have text in them, Excel will delete the text from the right-hand or bottom
cell (depending on the direction of the merger) and only keep that in the left-hand or top-
cell. Merge only empty cells to avoid confusion; if necessary cut and paste text to other
cell(s), merge the originals ones and then cut and paste the text back.

Split Cells

1. Select the merged cell you want to split. To split the merged cell, click Merge and Center.
The cells will split and the contents of the merged cell will appear in the upper-left cell of the
range of split cells.
Wrapping Text

When the text exceeds column width, it is possible to automatically have the text create a new
line at the column with (“wrap” the text).

To do so:

1. Select the cell or range of cells you wish to enable wrapping for.
2. Locate the Alignment area of the Home ribbon.
3. Click Wrap Text button.

Office 2019: PowerPoint Excel, and Access P a g e | 31


NOTE: If the text is a long word, the characters won't wrap (the word won't be split);
instead, you can widen the column or decrease the font size to see all the text. If all the
text is not visible after you wrap the text, you might have to adjust the height of the row.

On the Home tab, in the Cells group, click Format, and then under Cell Size click AutoFit
Row

Freezing Panes

Freezing panes allows you to select data that remains visible when scrolling in a sheet. For
example, keeping row and column labels visible as you scroll.

Freezing/Splitting Rows and Columns

To keep an area of a worksheet visible while you scroll to another area of the worksheet, you can
either lock specific rows or columns in one area by freezing panes.

Freezing vs. Splitting

When you freeze panes, Microsoft Excel keeps specific rows or columns visible when you scroll in
the worksheet. For example, if the first row in your spreadsheet contains labels, you might freeze
that row to make sure that the column labels remain visible as you scroll down in your
spreadsheet. A solid line indicates that the row is frozen to keep column labels in place when
you scroll.

When you split panes, Excel creates either two or four separate worksheet areas that you can
scroll within, while rows or columns in the non-scrolled area remain visible. This worksheet has
been split into four areas. Notice that each area contains a separate view of the same data.
Splitting panes is useful when you want to see different parts of a large spreadsheet at the same
time.

NOTE: YOU CANNOT DO BOTH THE SPLIT PANES AND FREEZE PANES AT THE
SAME.

Freeze Panes

1. On the worksheet, select the row or column that you want to keep visible when you scroll.
2. On the View tab, in the Window group, click the arrow below Freeze Panes.
3. Then do one of the following:
i. To lock one row only, click Freeze Top Row.
ii. To lock one column only, click Freeze First Column.
iii. To lock more than one row or column, or to lock both rows and columns at the
same time, click Freeze Panes.

Office 2019: PowerPoint Excel, and Access P a g e | 32


NOTE: You can freeze rows at the top and columns on the left side of the worksheet only.
You cannot freeze rows and columns in the middle of the worksheet.

Unfreeze Panes

1. On the View tab, in the Window group, click the arrow below Freeze Panes.
2. Click Unfreeze Panes.

Split Panes

1. To split panes, point to the split box at the top of the vertical scroll bar or at the right end of
the horizontal scroll bar.
2. When the pointer changes to a split pointer or, drag the split box down or to the left to the
position that you want.
3. To remove the split, double-click any part of the split bar that divides the panes.

Password Protect a Worksheet or Workbook

Data from a protected worksheet cells can be accessed but not overwritten.

NB: The password is optional; however, if you don't supply a


password, any user will be able to unprotect the sheet and
change the protected elements. Make sure you choose a
password you can remember, because if you lose the
password, you cannot gain access to the protected elements
on the worksheet.

1. In the Allow all users of this worksheet to list, select the


elements that you want users to be able to change.
2. Click OK, and if prompted retype the password.

NB: Worksheet can also be protected using the Review Tab.

Protect Worksheet Elements

1. On the Review tab, under Changes click Protect


Workbook.
2. Do one or more of the following:

a. To protect the structure of a workbook so that


worksheets in the workbook can't be moved,
deleted, hidden, unhidden, or renamed, and new
worksheets can't be inserted, select the Structure
check box.
b. To protect windows so that they are the same size
and position each time the workbook is opened, select the Windows check box.

Office 2019: PowerPoint Excel, and Access P a g e | 33


c. To prevent others from removing workbook protection, type a password, click OK, and
then retype the password to confirm it.

Protect a Workbook from Viewing or Editing

1. On the File menu, click Save As.


2. On the Tools menu, click General Options.
3. Do either or both of the following:

a. If you want users to enter a password before they


can view the workbook, type a password in the
Password to open box, and then click OK.
b. If you want users to enter a password before they
can save changes to the workbook, type a password
in the Password to modify box, and then click OK.

4. When prompted, retype your passwords to confirm them.


5. Click Save.
6. If prompted, click Yes to replace the existing workbook.

Lock or Unlock Specific Areas of a Protected Worksheet

1. When you protect a worksheet, all cells are locked by default, which means that they cannot
be edited.
2. To enable cells to be edited while leaving only some cells locked, you can unlock all the cells
and then lock only specific cells and ranges before you protect the worksheet.
3. You can also enable specific users to edit specific ranges in a protected worksheet.

Lock Only Specific Cells and Ranges in a Protected Worksheet

If the worksheet is protected, do the following:


1. On the Review tab, in the Changes group, click Unprotect Sheet.
2. The Protect Sheet command changes to Unprotect Sheet when
a worksheet is protected.
3. If prompted, type the password to unprotect the worksheet.
4. Select the whole worksheet by clicking the Select All button.
5. On the Home tab, in the Font group, click the Format Cell
Font dialog box launcher. You can also press Ctrl+Shift+F or Ctrl+1
6. On the Protection tab, clear the Locked box and then click OK. This unlocks all the cells on the
worksheet when you protect the worksheet. Now, you can choose the cells you specifically
want to lock.
7. On the worksheet, select just the cells that you want to lock.
8. Bring up the Format Cells dialog box again (Ctrl+Shift+F).
9. This time, on the Protection tab, select the Locked box and then click OK.
10. On the Review tab, in the Changes group, click Protect Sheet.

Office 2019: PowerPoint Excel, and Access P a g e | 34


11. In the Allow all users of this worksheet to list, select the elements that you want users to be
able to change.
12. In the Password to unprotect sheet box, type a password for the sheet, click OK, and then
retype the password to confirm it.
13. The password is optional. If you do not supply a password, any user can unprotect the sheet
and change the protected elements.
14. Make sure that you choose a password that is easy to remember, because if you lose the
password, you won't have access to the protected elements on the worksheet.

DATA VALIDATION

With Excel's data validation tools, you can control how users input data into workbooks and ensure
data is entered consistently and accurately. You can control the dates, the times, even the length
of the text they enter, or simply provide a list of acceptable choices to eliminate any possible
mistakes.

If you share one sheet to use with lots of people, you might want
to use this feature to validate data entry.

Data Validation checks whether another user(s) enter data in


accordance with the criteria imposed by you. Follow the
example below to learn how validation works.

Enter Positive Integers (Negative Numbers Not Allowed)

1. Select a portion of the sheet, which you establish criteria for,


then at the ribbon, Select Data and under Data Tools click
Data Validation.
2. In the Settings tab, set the criteria, as in the following screenshot.
3. In the Input Message tab, enter the message which appears when you select a cell in the area
controlled by the validation.
4. Error Alert appears when a user types the number did not meet the conditions imposed (e.g.
negative, fraction, zero).
5. You can also set the Style, which is a reaction to the validation. Excel provides three styles:
Stop, Information and Warning. Only Stop warning is a way to not allow the user entered an
invalid value. Information and Warning styles allow for such a possibility.
6. Let us see how it looks in your worksheet. Now you see a comment in the cell.
7. After entering the number which is less than 0 appears alert message. Data Validation does
stop the possibility of entering an incorrect value.

Entering a Specific Number of Characters

This approach will be useful, for example, when you enter identity numbers, or in such cases
where the user must enter a fixed number of characters. Excel reports error if the entry gets longer
or shorter.

Office 2019: PowerPoint Excel, and Access P a g e | 35


Entering Only the Current Date

If you will use the date function =TODAY() so the procedure will cause the user will be able to
enter only the current date.

If the cells are filled with consecutive dates with any of the options Copy-Paste data validation
rules will not work! Validation works only for the data entered from the keyboard!

Drop-down List

If you are completing the data sheet enter same information (e.g., days of the week, months) you
can use a drop-down list to validate.

First, prepare list of all possible options. In this example, these are the days of the week. Then on
the Settings tab, select the Source list and select cell address.

Drop-down list works like that:

Accepting Text Only

To get the selected cell could only enter text (no numbers), use the following formula:

=ISTEXT(A1)

Acceptance of Value Only if it is Greater Than the Value in the Previous Cell

The following formula for verifying the accuracy of the data allows the user to enter the cell only
a value that is greater than the value contained in the cell located directly above it:

Class Exercise 2: Data Validation

1. Download Data Validation Files (instruction PDF file and Excel file) from the ICT122 Eduhub
Page.

MAKE SURE YOU HAVE COMPLETED THE ABOVE CLASS EXERCISE 2 HAS
BEEN CHECKED BY THE INSTRUCTOR BEFORE MOVING TO THE NEXT
PART OF THE LAB.

Office 2019: PowerPoint Excel, and Access P a g e | 36


RENAMING A WORKSHEET

There are different ways to rename an Excel worksheet.

Using Office Ribbon

1. Click the Home menu and navigate to Cells section.


2. Click the Format drop down arrow and select Rename Sheet
(Organize Sheets) from the displayed menus.
3. This would highlight, sheet tab for editing as shown on the right.

Using Context Menu

Right click on the Sheet tab and select Rename from the menu list.

Double click the Sheet tab

This is the easiest option to rename a sheet is


to click the Sheet tab and rename it simply
double.

HEADERS AND FOOTERS

To have a consistent header or footer on each page of a


workbook this is achieved through the Page Layout tab from
the Sheets Options group..

The Header & Footer Tools options related to the header and
footer sections of a workbook.

The Header & Footer group provides the ability to select a


predefined header or footer.

FORMATTING SPREADSHEETS

To further enhance a spreadsheet, you can format a number of elements such as text, numbers,
colouring, and table styles. Spreadsheets can become professional documents used for company
meetings or can even be published.

Office 2019: PowerPoint Excel, and Access P a g e | 37


Formatting Numbers

In Excel, the format of a cell is separate from the data that is stored in the
cell. For example, numbers in cells will default as rounded numbers, date
and time may not appear as anticipated. After you type numbers in a cell,
you can change the format in which they are displayed to ensure the
numbers in your spreadsheet are displayed as you intended.

1. Click the cell(s) that contains the numbers that you want to format.
On the Home tab, in the Number group, click the arrow next to the
Number Format box, and then click the format that you want. If you
are unable to format numbers in the detail you would like that you
can click on the More Number Formats at the bottom of the Number
Format drop down list.

2. In the Category list, click the format that you want to use,
and then adjust settings of the Format Cells dialog box. For
example, if you are using the Currency format, you can
select a different currency symbol, show more or fewer
decimal places, or change the way negative numbers are
display.

Cell Borders

By using predefined border styles, you can quickly add a


border around cells or ranges of cells. If predefined cell
borders do not meet your needs, you can create a custom
border.

NOTE: Cell borders that you apply appear on printed pages. If you do not use cell borders but
want worksheet gridline borders for all cells to be visible on printed pages, you can display the
gridlines.

Apply Cell Borders

1. On a worksheet, select the cell or range of cells that you want to add a border to, change the
border style on, or remove a border from.
2. Go to the Home tab, in the Font group.
3. Click the arrow next to Borders.
4. Click on the border style you would like.
5. The border will be applied to the cell or cell range.

NOTE: To apply a custom border style, click More Borders. In the Format Cells dialog box, on the
Border tab, under Line and Color, click the line style and color that you want.

Office 2019: PowerPoint Excel, and Access P a g e | 38


Remove Cell Borders

1. Go to the Home tab, in the Font group.


2. Click the arrow next to Borders.
3. Click No Border.

NOTES: The Borders button displays the most recently used border style. You can click the
Borders button (not the arrow) to apply that style.

Cell Styles

You can create a cell style that includes a custom border, colours, and accounting formatting.
1. On the Home tab, in the Styles group, click Cell Styles.
2. Select the different cell style option you would like applied to your spreadsheet.

NOTE: If you would like to apply a cell fill and a cell border, select the cell fill colour
first ensure that both formats are applied.

Office 2019: PowerPoint Excel, and Access P a g e | 39


Class Exercise 3: Formatting

This exercise is designed to help you apply the information learnt from this and the previous
practical sessions.

Remember to save your work often. Select a new worksheet before beginning the exercise.

1. In cell (A1) type Loose Change Cafe.


2. In cell (A2) type Week of (mm/dd/yy) to (mm/dd/yy) [add 6 days to the end date].
3. In cell (A3) type Daily Sales Revenue.
4. In cell (A5) type Week Day.
5. In cell (A6) type Cash Receipts.
6. In cell (A10) type Total Revenue.
7. In cell (A11) type Average.
8. In cell (C5) type Monday and then press the Tab key. Select cell (C5) and then drag the AutoFill
handle across to cell (H5). Release the mouse button.
9. In cell (C6) type the number (1200).
10. In cell (C7) type the number (1500).
11. Select cell (C6) and C7, drag the fill handle to cell (H6).
12. Right-click anywhere within the highlighted cells and the Format Cells dialog box will open.
13. Choose the tab Number and the category Currency. Note: Inspect that the text boxes Decimal
places and Symbol include the number (2) for decimal places and the (BWP) symbol.
14. Merge cell (A1) through to cell (H1).
15. Click the Fill button in the Font group and apply the background color yellow. Within the same
group, click the Border list arrow and select Outside Borders (7th from the top).
16. Click the Font size list arrow and change the font size to (24). Repeat the same steps to the
Font box and change the font to Garamond and the style to Bold. Press Enter.
17. Repeat the prior steps and format cell (
18. A2), except this time change the font to size (14) Bold. Do not add a border, background color,
or change the font.
19. Repeat the same steps for cell (A3).
20. Select the cell range (A5:H5) and change the font size to (11) Bold.
21. Reselect the same range and add a border. Click on the Top & Bottom Border.
22. Select the cell range (A6:H6) and change the font size to (11) Bold.
23. Repeat step (7) for cell range (A10:A11) and add a Thick Black Border.
24. Adjust the headings for columns (A) and (B). Place the mouse pointer on the fine line between
both column headings and then double-click the mouse button.
25. Adjust the column width manually for column (B) to (9.43).
26. AutoFit columns (C, D, E, F, G, and H) by holding down the Ctrl key while clicking on each
column heading. Click the Format list arrow in the Cell group and select AutoFit Column Width.
The selected columns are adjusted to their contents.
27. Select the cell range (C5:H5) and then center the headings.

Office 2019: PowerPoint Excel, and Access P a g e | 40


Class Exercise 4: General Formatting

Do this the following exercise in Sheet4 and name it Sure Balance Checkbook.
1. Enter the text below in the cells indicated.

A1: Sure Balance Checkbook


A3: Ck. #
B3: Date
C3: Item Description
D3: Debit
E3: Credit
F3: X
G3: Balance

2. Modify column widths for columns A through F. Instead of selecting the best fit option,
precisely indicate the column width desired. Follow the steps below.
a. Open the FORMAT menu, Select the COLUMN option, Select the WIDTH option.
b. Type the desired number of columns in the box labeled “Column Width"
c. (e.g., 5). Click on <OK>.

3. Use the following widths for each column:

Column A: 5; Column B: 8; Column C: 30; Column D: 10; Column E: 10; Column F: 1;Column
G: 12

4. Format the numbers to show dollars and cents for all entries in columns D, E, and G. Follow
the steps below.
a. Click on the letter at the top of the column to be formatted. (The entire column
should turn dark.)
b. Open the FORMAT menu.
c. Select the CELLS option.
d. The NUMBER option automatically should be selected (if not, click on the tab
labelled NUMBER).
e. Under the Category label, select the option CURRENCY.
f. Under the Format Codes label, select the format -$1,234.10 which is the third
choice.

5. Format column B to enter the date of transactions. Follow the steps above but select the DATE
as the category option and M/D/YY as the format codes option which is the first choice.
6. Enter the formulas below in the cells indicated. G4: =-D4+E4 : G5: =G4-D5+E5
7. Enter the information below in the rows indicated.

Office 2019: PowerPoint Excel, and Access P a g e | 41


Row Ck. # Date Item Description Debit Credit
4 30/01/2023 January Paycheck 1795.86
5 100 01/02/2023 Shell Oil Co. 42.64
6 101 01/02/2023 Pink Palace Enter. 87.34
7 04/02/2023 Cash (Auto Teller) 50
8 102 06/02/2023 Dr. D. J. Houston 75
9 103 07/02/2023 Rent 800
10 10/02/2023 Drug Sales 2500.00
11 104 11/02/2023 Bail (Drug Arrest) 500
12 105 12/02/2023 Benny the Weasel 3200
13 14/02/2023 Rainy Day Q/Fund 500.00

8. Copy the formula from cell G5 to cells G6 through G13.

MAKE SURE YOU HAVE COMPLETED THE ABOVE CLASS EXERCISES 3 AND
4 AND HAVE BEEN CHECKED BY THE INSTRUCTOR BEFORE MOVING TO
THE NEXT PART OF THE LAB.

Office 2019: PowerPoint Excel, and Access P a g e | 42


WEEK 4: CELL REFERENCING
OVERVIEW

More often than not when we create a are referring to the content of cell A1 only,
formula using one of Excels built-in functions while in the second example we would be
we will be referring it to a cell or range of referring to the contents of cells A1, A2, A3,
cells. An example of a single cell reference A4, A5, A6, A7, A8, A9, A10. Using the
would be A1. reference A1:A10 is just a simple method
that Excel will automatically recognise. If we
For you to complete this next exercise, click use the reference A1:C5 we are telling Excel
+ next to sheet1 to create sheet2 to refer to the contents of cells A1, A2, A3,
A4, A5, B1, B2, B3, B4, B5, C1, C2, C3 C4, C5.
An example of a range of cells reference
would be A1:A10. For the first example we

CALCULATIONS

Simple Formula Calculations

A formula begins with an equal sign (=). A formula is normally typed in the Formula Bar.

Formula Bar

It can also be typed in the active cell and the whole formula will be displayed in the formula bar.
Any part of the formula in brackets will be calculated first. Indices will be next. Multiplication and
division will be next. Addition and subtraction will be calculated last.

1. A formula will follow the order of operations (BIMDAS).


B Brackets ( ); I Indices ^; M Multiplication *; D Division / ; A Addition + ; S Subtraction –
2. A formula can refer to other cells in the spreadsheet using cell references.
3. If any part of the formula is referring to text, the text must be enclosed in quotation marks
“ ”.
4. The cells referred to in a formula cannot include the cell the answer will be in. This will
cause a circular reference error.

Using Cell Referencing

1. Open a new workbook save it at Practical Exercise 1. In Sheet1 do items 2 - 6


2. Enter the number 5 in cell B1.
3. Enter the number 10 in cell B2.
4. Enter this formula =b1+b2 in cell B3.
5. Press [Enter] to complete the formula. Excel will calculate the result.
6. Change the number in cell B2 to 12 and press Enter. The result of the formula will be re-
calculated (if it does not recalculate on its own you can press [F9] to force recalculation).

Office 2019: PowerPoint Excel, and Access P a g e | 43


Using the Mouse for Cell Referencing

Creation of a formula can be made easier by using the mouse to create cell references. Still using
Practice Exercises 1 workbook to do the following exercises.

1. Enter the number 10 in cell C1; Enter the


number 20 in cell C2.
2. Click in cell C3 and type a = sign.
3. Click on cell C1. The reference for that cell will
appear in the formula.
4. Type a + sign.
5. Click on cell C2. The reference for that cell will appear in the formula.
6. Check that the formula reads =C1+C2 and press Enter. Your table should look like the above
example.

Referencing Cells in Formulas

You can include or reference other cells in a formula. When you do, the result of the formula
depends on the values in the referenced cells and changes automatically when the values in the
referenced cells change. This is extremely powerful in what-if scenarios.

To see how this works, select worksheet Practice Exercises 2 and enter 10 in cell A1. Now select
cell A2 and type =A1*2, and press ENTER. The value in cell A2 is 20. If you change the value in cell
A1 from 10 to any value, the value in cell A2 will also change. Cell references are especially helpful
when you create complex formulas, or conduct what-if analysis.

Class Exercise 1: Formulas

Enter the following information into Practice Exercises 2 worksheet (ignore any formatting) in
columns A, B, and C, and in rows 1 through 6. Then calculate the Total Cost for the Semester 1
using a formula to add up the individual Costs (Tuition, Housing, etc.).

Costs Semester1 Semester2


Tuition 10000 10000
Housing 5000 5000
Books 1000 700
Spending 1500 1000
Total

The most logical solution would be to type the formula ’=B2+B3+B4+B5’ into cell B6. You can also
enter formulae by using the point mode, where you either click on a cell with your left mouse
button or you use the arrow keys. To enter ‘=B2+B3+B4+B5’ into cell B6 using the point:

1. Click on cell B6 to make it active.


2. Type ’=’.
3. Use the up arrow key to move to cell B5, or click on cell B5.

Office 2019: PowerPoint Excel, and Access P a g e | 44


4. Type ’+’.
5. Use the up arrow or mouse to add cells B4, B3, and B2 in the same fashion.
6. Press Enter when you are finished entering the formula.

You’ll notice that the calculation executes immediately after the formula is typed into the cell and
entered by pressing either the Enter or Tab key or by clicking the check mark in the formula bar.
The result of the calculation is displayed in the cell (i.e., in B6). The formula itself is now visible in
the formula bar.

Automatic Calculation

Let us illustrate the concept of automatic calculation with a practice exercise:

Class Exercise 2 – Adding Several Numbers Together

Let us make a change to the Costs for Semester 1 and Semester 2 spreadsheet and note how Excel
automatically recalculates the formulas and functions we have already entered.

1. Change the amount entered in cell C2 from ’10000’ to ’15000’.


2. Notice how all the calculations referencing cell C2 automatically changed.

To reiterate the use of cell addresses in formulae and functions, imagine we had constructed our
formulae and functions by typing the actual numbers contained in the cells instead of the cell
addresses. That is, to calculate the Total Cost for semester 1 we had entered the formula
’=10000+5000+1000+1500’.

What would happen if we changed the amount entered in cell C2 from ’10000’ to ’15000’ as
suggested above?

Obviously, our calculation defined by our formula would not automatically change, and we would
have to edit the formula by hand. Imagine if the cell we modified was referenced by ten separate
formulae or functions. That would be a lot of editing. If automatic calculation is activated, Excel
automatically recalculates the result.

NB: You can check to make sure automatic calculation is turned on:

1. Go to Calculation menu under Formulas tab.


2. Click on Calculation Options
3. Select Automatic if it is not already selected.
4. Click OK.

Office 2019: PowerPoint Excel, and Access P a g e | 45


CELL REFERENCING

Create a Cell Reference on the Same Worksheet

1. Click the cell in which you want to enter the formula.


2. In the formula bar , type = (equal sign).
3. Do one of the following:
• Cell reference To create a reference, select a cell or range of cells on the same
worksheet.

Cell references and the borders around the corresponding


cells are color-coded to make it easier to work with them.

1. The first cell reference is B3, the color is blue, and the cell range has a blue border with square
corners.
2. The second cell reference is C3, the color is green, and the cell range has a green border with
square corners. Save and close the workbook.
You can drag the border of the cell selection to move the selection or drag the corner of the border
to expand the selection.

Relative and Absolute Cell References

In Excel there are three types of cell references, these are Relative, Absolute and Mixed.

Relative Cell Reference

Each cell on an Excel worksheet has its own unique address; e. g. A1 is the relative address of the
first cell on all worksheets, while XFD1048576 is the relative address of the last cell on all
Worksheets. The reason why they are called relative is because they are relative to the cell they
are used in. This will be best explained by a simple example.

1. Open workbook you saved in the previous exercise.


2. Delete all the contents of workbook by selecting the text and pressing delete.
3. In cell A1 type the number 1 and in cell A2 type the number 2.
4. Select cells A1:A2 and use the Fill Handle to fill down to A10, so that we have the numbers
1 to 10 in cells A1:A10.
5. In cell B1 type this simple reference: =A1 and push Enter. Select cell B1 and do one of the
following.
6. Copy and then select B2:B10 and paste.
7. Double click the Fill Handle.
8. Save

Office 2019: PowerPoint Excel, and Access P a g e | 46


You should now have the numbers 1 to 10 in both A1:A10 and B1:B10. This is because we typed a
relative cell reference in cell B1 (=A1), which is telling Excel to make cell B1 equal the value of the
cell one column to the left on the same row, i.e. A1. So when we copy the reference in B1, i.e. =A1
and paste it into cell B2 Excel is still going to reference the cell one column to the left on the same
row, i.e. A2. Copying the same cell (B1) and pasting it into cell B3 again tells Excel to reference the
cell one column to the left on the same row, i.e. A3.

Let us now copy the content of cell B1 and paste it into cell D1, this time we should get the result
0 (zero). If you click in cell D1 and look in the Formula bar you will see the relative cell reference:
=C1. The reason we get the result of 0 (zero) is because the value of an empty cell is 0 (zero).

By default, MS Excel uses relative reference. Follow the steps below to practice cell referencing:

1. Open a new workbook and save it as Cell Referencing and rename Sheet1 as Relative
2. Type the information as shown below, the cells that captures Quantity, Price and Amount
should be formatted in Number data type.

(See the formula in cell D2. Cell D2 references (points to) cell B2 and cell C2. Both references are
relative. The formula in D2 is calculating the Amount).

3. Select cell D2, click on the lower right corner of cell D2 and drag it down to cell D5.

(Cell D3 references cell B3 and cell C3. Cell D4 references cell B4 and cell C4. Cell D5 references cell
B5 and cell C5. In other words: each cell references its two neighbors on the left).

In relative reference, you refer to cell that is above or below or left or right to several rows or
columns. For example, if you refer to cell D2 from F2, you are referring to a column that is two
columns to the left of cell D2 and in the same row (the second ‘2’ row). When a formula that
possesses a relative reference is copied from one cell to another cell, the value in the copied cell
also changes. i.e., if you copy a formula =C2+D2 from E2 to the cell F2, the formula in F2 adjusts
in such a way that when the cell F2 is dragged downwards by one row, the formula automatically
changes to =C3+D3 and places the resulting value of =C3+D3 in cell F3.

Office 2019: PowerPoint Excel, and Access P a g e | 47


Class Exercise 3: Relative Reference

1. Using the worksheet named Relative.


2. Enter two different numbers in cells (A1) and (A2), then press the Enter key after the typing
the first number.
3. In cell (A3) type (=A1*A2), and then press the Enter key. What does Cell (A3) display?
4. Now copy that formula to cell (B3). What has been displayed in cell (B3)?
5. Enter the any number in both cells (B1) and (B2); what is the result in (B3)?

Let us work with a new data example. Enter the following information into a new worksheet
(ignore any formatting) in columns A, B, and C, and in rows 1 through 5. Then define a formula in
cell D2 to calculate the Cost of the group of Biology Textbooks and copy the formula into cells D3
through D5.

Textbook Quantity Price


Biology 4 99.99
Chemistry 2 79.95
Physics 7 65.99
English 12 49.99

The most logical solution would be to type the formula ‘=B2*C2’ into cell D2. We may also want
to add the column label of Cost into cell D1. We can then use one of the data copying methods to
copy and paste the formula into the desired cells. Compare the formulae in cells D2 through D5
by looking in the Formula bar. You will notice that the formulae are the same except that the row
numbers were automatically changed (from 2 through 5) because of the relative cell referencing.

Advantages of Relative Cell References

• A formula can quickly be copied to a range of other cells.


• When replicated, the relative cell reference will automatically update itself.

Disadvantages of Relative Cell References

• Any mistake in a formula will be replicated to all other cells that are copied from the
original formula.
• If a formula is referencing just one cell, it will not stay in that cell once copied to other cells.
• If a change is made to the original formula, it will need to be recopied to all the other cells.

Absolute Cell Reference

Office 2019: PowerPoint Excel, and Access P a g e | 48


Let us now look at what an Absolute cell reference is. Basically, an absolute cell reference is a
reference to a cell that does not change no matter where it is copied. Again, this will be easier to
see by using an example.

1. Delete the contents of cells B1:B10 and D1.


2. In cell B1 type the absolute cell reference =$A$1 and push Enter. Select cell B1 and either.
3. Copy and then select B2:B10 and paste.
4. Double click the Fill Handle

This time you should have the number 1 in cells B1:B10 and if you select any cell in B1:B10 and
look in the Formula bar, they will all have the absolute cell reference =$A$1. This is because by
using the $ (dollar sign) we are telling Excel to always refer to the same cell no matter where we
copy this reference to. The $ in front of the A ($A) is telling Excel to make the column reference
absolute, while the $ in front of the 1 ($1) is telling Excel to make the row reference absolute. So,
the reference in its entirety is what is known as an Absolute cell reference.

In an absolute cell reference, a dollar sign ($) precedes both the column letter and the row
number. You can also have a mixed reference in which the column is absolute, and the row is
relative, or vice versa. To create a mixed reference, you use the dollar sign in front of just the
column letter or row number. Here are some examples:

Column & Row Absolute ($A$1)

Column Absolute ($A1)

Row Absolute (A$1)

Nothing Absolute (A1)

A1 Relative reference – row and column references will both change.


$A2 Mixed reference – Column reference stays constant; row reference will change.
A$2 Mixed reference – Row reference stays constant; column reference will change.
Absolute reference – Row and column reference will both stay constant if the formula
$A$2
is copied to another location.

NOTE: Pressing F4 repeatedly over a reference (cell) will allow you to switch
between making the column, the row, or nothing ‘Absolute. Try it and see!!! Delete
the values in A1 and A2.

Class Exercise 4: Absolute Reference

Again, the best way to see this is by using a small example. Go to Sheet 2 in the same workbook
and rename the worksheet Absolute Reference 1 and capture information on the figure below:

Office 2019: PowerPoint Excel, and Access P a g e | 49


In case, if you wish to maintain the original references as they were, then you should make use of
the absolute references. If you want to make the above example retain the original reference
when it is copied, then you should precede the columns A2 and B2 and the row number by a Dollar
($) symbol. i.e., you should use the formula as =$C$2+$B$2 so that when you copy the formula
the original reference is retained.

Class Exercise 5: Absolute Reference

1. This is another exercise on absolute reference.


2. Create the following table starting in cell B1. Go to cell H13, $ symbol is placed in front of the
column letter and row number of cell H13 ($H$13) in the formula of cell E13.
3. Now quickly drag this formula to the other cells as below.

The reference to cell H13 is fixed (when we drag the formula down and across). As a result, the
correct lengths and widths in inches will be calculated.

Office 2019: PowerPoint Excel, and Access P a g e | 50


Class Exercise 6: Absolute Reference

The following exercise demonstrates what happens when an absolute cell reference is not used.

1. Create the following table in worksheet named Practice Exercises 2 in columns A through F
and rows 1 through 4 (ignore any formatting).

SUBJECT TRIAL 1 TRIAL 2 TOTAL VARIANCE CONSTANT


A 500 650 0.03
B 50 567
C 670 780

2. In cell D2, calculate the Total of Trial 1 and Trial 2 for subject A using the SUM function.
3. Use the Autofill feature to copy the function for subjects B and C.
4. In cell E2 enter the formulas ‘=D2*F2’ either by typing or by using the point mode.
5. Use the Autofill feature to copy the formula for subjects B and C.
• NOTE: The results of the formula for subjects B and C are incorrect. This is because
the formula referenced the CONSTANT using a relative cell reference.
6. Edit the formula in cell E2 to reference the CONSTANT using an absolute cell reference:
‘=D2*$F$2’.
7. Use the Autofill feature to copy the correct formula for subjects B and C.

Advantages of Absolute Cell Reference

• The 'absolute' part of the formula will not change even if copied elsewhere.
• Just one cell needs to be changed to update all of the cells related with a formula.

Disadvantages of Absolute Cell Reference

• If a range of cells are using a formula which has an absolute cell reference, a change will
affect all cells. You might not want this to happen.

If you grasped this concept, we could move on to what is known as either an:

• Relative row absolute column reference or;


• Absolute row relative column reference.

Office 2019: PowerPoint Excel, and Access P a g e | 51


Mixed Cell Reference – (Relative Row Absolute Column)

Try this:

1. Delete the contents of cells B1:B10.


2. In B1 type the Relative row absolute column reference: =$A1 and push Enter. Select cell
B1 and either.
3. Copy and then select B2:B10 and paste.
4. Double click the Fill Handle

You will have the numbers 1 to 10 in cells B1:B10. This is because the row portion of the reference
(1) is relative. Now copy cell B10 to cell D1 and you should get the result 1. This is because the
column portion of the reference ($A) is absolute. If you click in any cell in the range B1:B10 or D1
and look in the Formula bar you will see that the row portion is always relative to the row the
reference resides in, while the column reference is always absolute.

The same principle also applies to any reference that has an absolute row relative column
reference. Again, this can be best seen via the use of a small example.

Mixed Cell Reference (Absolute Row Relative Column Reference)

Try this:

1. Delete the contents of cells B1:B10 and D1.


2. In B1 type the absolute row relative column reference: =A$1 and push Enter. Select cell
B1 and either.
3. Copy and then select B2:B10 and paste.
4. Double click the Fill Handle.

You will have the number 1 in cells B1:B10. This is because the row portion of the reference ($1)
is absolute. Now copy cell B10 to cell D1 and you should get the result 0, this is because the column
portion of the reference (A) is always relative to the column the reference resides in. If you click
in any cell in the range B1:B10 and look in the Formula bar you will see that the row portion is
always absolute. If you click in cell D1 and look in the Formula bar you should see =C$1.

Class Exercise 7: Mixed Cell Reference

Let us see how it works using an example.


Create the data set below in the Mixed Cell
Reference worksheet, calculate the three
tiers of commission based on the percentage
value in cell E2, F2, and G2. Enter this
=$B4*$C4*E$2 formula in cell E4 and copy
for all cells.

Office 2019: PowerPoint Excel, and Access P a g e | 52


Mixed Reference (Absolute and Relative References)
Class Exercise 8: Mixed Cell Reference

1. Insert a new worksheet and name it as Mixed Reference 2 and type information below:

2. We want to copy this formula to the other cells quickly. Drag cell F2 across one cell and look
at the formula in cell G2. Please note what is happening, the reference to the price should be
a fixed reference to column B.
3. Solution: place a $ symbol in front of the column letter of cell B2 ($B2) in the formula of cell
F2. In a similar way, when we drag cell F2 down, the reference to the reduction should be a
fixed reference to row 6. Solution: place a $ symbol in front of the row number of cell B6 (B$6)
in the formula of cell F2.

Result:

Note: If we do not place a $ symbol in front of the row number of B2 (this way we allow the
reference to change from B2 (Jeans) to B3 (Shirts) when we drag the formula down). In a similar
way, we don't place a $ symbol in front of the column letter of B6 (this way we allow the reference
to change from B6 (Jan) to C6 (Feb) and D6 (Mar) when we drag the formula across).

4. Now quickly drag this formula to the other cells. The references to column B and row 6 are
fixed.

External Cell Reference in Excel

When calculating data in Excel, you may often find yourself in a situation when you need to pull
data from another worksheet or even from a different Excel file.
You just need to create a link between the worksheets (within the same workbook or in different
workbooks) by using what is called an external cell reference or a link.

An external cell reference in Excel is nothing more than a reference to a cell or a range of cells
outside the current worksheet. The main benefit of using an Excel external reference is that

Office 2019: PowerPoint Excel, and Access P a g e | 53


whenever the referenced cell(s) in another worksheet changes, the value returned by the external
cell reference is automatically updated.

How to Reference another Sheet in Excel

To reference a cell or range of cells in another worksheet in the same workbook, put the worksheet
name followed by an exclamation mark (!) before the cell address. In other words, in an Excel
reference to another worksheet, you use the following format:

Reference to an individual cell: Sheet_name!Cell_address

For example, to refer to cell A1 in Sheet2, you type Sheet2!A1.

Reference to a range of cells: Sheet_name!First_cell:Last_cell

For example, to refer to cells A1:A10 in Sheet2, you type Sheet2!A1:A10.

Note. If the worksheet name includes spaces or non-alphabetical characters, you


must enclose it in single quotation marks. For example, an external reference to cell
A1 in a worksheet named Project Milestones should read as follows: 'Project
Milestones'!A1.

In a real-life formula, which multiplies the value in cell A1 in 'Project Milestones' sheet by 10, an
Excel sheet reference looks like this: ='Project Milestones'!A1*10

Creating a Reference to Another Sheet in Excel

When writing a formula that refers to cells in another worksheet, you can of course type that other
sheet name followed by an exclamation point and a cell reference manually, but this would be a
slow and error-prone way.

A better way is point to the cell(s) in another sheet that you want the formula to refer to, and let
Excel take care of the correct syntax of your sheet reference. To have Excel insert a reference to
another sheet in your formula, do the following:
1. Start typing a formula either in a destination cell or in the formula bar.
2. When it comes to adding a reference to another worksheet, switch to that sheet and select
a cell or a range of cells you want to refer to.
3. Finish typing the formula and press the Enter key to complete it.

Office 2019: PowerPoint Excel, and Access P a g e | 54


For example, if you have a list of sales figures in sheet Sales and you want
to calculate the Value Added Tax (19%) for each product in another sheet
named VAT, proceed in the following way:
1. Start typing the formula =19%* in cell B2 on sheet VAT.
2. Switch to sheet Sales and click on cell B2 there. Excel will
immediately insert an external reference to that cell, as shown in
the following screenshot, Press Enter to complete the formula.

Note. When adding an Excel reference to another sheet using the above method, by default
Microsoft Excel adds a relative reference (with no $ sign). So, in the above example, you can just
copy the formula to other cells in column B on sheet VAT, the cell references will adjust for each
row, and you will have VAT for each product correctly calculated.

In a similar manner, you can reference a range of cells in another


sheet. The only difference is that you select multiple cells on the
source worksheet. For example, to find out the total of sales in cells
B2:B5 on sheet Sales, you would enter the following formula:
=SUM(Sales!B2:B5)

NOTE: The results of the formula for subjects B and C are now correct. The Total value
adjusts because of the relative cell reference, but the CONSTANT value does not because
of the absolute cell reference.

Class Exercise 9 – Cell Reference

1. Copy the file BEC 2022 BGSCE.xlxs from the ICT122 Eduhub Page under Week 4 Practical
Exercises to carry out the following:

a. Calculate the CA for each student using the weights provided in K2:L6.
b. Calculate the Final Mark for each student in the worksheet Totals using CA and Exam Mark
values and weightings from the Marks worksheet

2. Copy the file cell-references.xls from the ICT122 Eduhub Page under Week 4 page:
a. Calculate the CA for each student using the weights provided.

IT IS IMPORTANT THAT YOU MUST COMPLETE CLASS EXERCISE 9 IN CLASS. IF YOU


ARE UNABLE TO COMPLETE IT, PLEASE MAKE TIME TO COMPLETE THIS AT YOUR
OWN TIME.

Office 2019: PowerPoint Excel, and Access P a g e | 55


HOW TO DEFINE AND EDIT A NAMED RANGE IN EXCEL

A named range, range name, or defined name all refer to the same object in Excel; it's a
descriptive name — such as Jan_Sales or June_Profits — that is attached to a specific cell
or range of cells in a worksheet or workbook. Named ranges make it easier to use and identify
data when creating charts, and in formulas.

Additionally, since a named range does not change when a formula is copied to other cells, it
provides an alternative to using absolute cell references in formulas. There are three methods for
defining a name in Excel: using the name box, the new name dialog box, or the name manager.
This article has instructions for the name box only.

DEFINING AND MANAGING NAMES WITH THE NAME BOX

One way, and possibly the easiest way, of defining names is using the Name Box, located
above column A in the worksheet. You can use this method to create unique names that are
recognized by every sheet in a workbook. To create a name using the Name Box as shown in the
image above:

1. Open the file named Sales Rep from the ICT122 Eduhub Page, under Week 4
2. Highlight the desired range of cells in the worksheet.
3. Type the desired name for that range in the Name Box, such as Jan_Sales.
4. Press the Enter key on the keyboard. The name is displayed in the Name Box.

The name is also displayed in the Name box whenever the same range of cells is highlighted in the
worksheet.

Naming Rules and Restrictions

Syntax rules to remember when creating or editing names for ranges are as follows:

1. A name can't contain spaces.


2. The first character of a name must be either a letter, underscore, or backslash.
3. The remaining characters can only be letters, numbers, periods, or underscore characters.
4. The maximum name length is 255 characters.
5. Uppercase and lowercase letters are indistinguishable to Excel, so Jan_Sales and jan_sales are
the same name by Excel.
6. Cell reference cannot be used as names such as A25 or R1C4.

Deleting Name Range(s) using Names Manager

1. On the Formulas tab, in the Defined Names group, click Name Manager.
2. In the Name Manager dialog box, click the name that you want to change.
3. Select one or more names by doing one of the following: To select a name, click it. ...
4. Click Delete.

Office 2019: PowerPoint Excel, and Access P a g e | 56


Editing/Renaming Name Ranges using Names Manager

1. Click OK to confirm the deletion.


2. Go to the Formulas tab and click on Name Manager.
3. The Name Manager dialog box will list all the Named Ranges in that workbook. Double
click on the Named Range that you want to edit.
4. In the Edit Name dialog box, make the changes.
5. Click OK.
6. Close the Name Manager dialog box.

Office 2019: PowerPoint Excel, and Access P a g e | 57


WEEK 5: USING FUNCTIONS AND FORMULAS TO
CREATE AND INTERPRET DATA

OBJECTIVES

• Spreadsheet Calculation
➢ Simple Formula Calculations
➢ Simple Functions Calculations

Functions

Functions are a special kind of formula that can simplify complex calculations. The following
exercises will demonstrate the use of functions.

Class Exercise 1 – Adding Several Numbers Together

1. Select Sheet2 enter any value in the range B2:B8.


2. Click in cell B9.
3. Begin your formula with a = sign and then click on cell B2.
4. Type a + sign and click on cell B3.
5. Complete the formula so that it looks like the one below .

=B2+B3+B4+B5+B6+B7+B8

You will get the correct answer, but it’s a long formula. Adding together 50 or 100 cells like this
would be a tedious process.

A function is a predefined formula that performs calculations using specific values in a particular
order. All spreadsheet programs include common functions that can be used for quickly finding
the Sum,Average, Count, Maximum Value, and Minimum Value for a range of cells. In order to
use functions correctly, you'll need to understand the different parts of a function and how to
create arguments to calculate values and cell references.

To work correctly, a function must be written a specific way, which is called the syntax. The basic
syntax for a function is an equals sign (=), the function name (SUM, for example), and one or
more arguments. Arguments contain the
information you want to calculate. The function in
the example below would add the values of the
cell range A1:A20.
Functions can be used to take the hard work out
of many types of calculations in Excel.

=NameOfFunction(information to be calculated)

Office 2019: PowerPoint Excel, and Access P a g e | 58


There are hundreds of functions built-in to Excel and custom functions can be created. The most
used function is the Sum function.

Note If you want to add together more than one group of cells, you can separate
each cell range with a comma.
E.g. =SUM(C2:C8,E2:E8,G2:G8)
This would add cells C2 to C8 and E2 to E8 and G2 to G8

MS Excel provides in-built formulae that are frequently used so that we do not have to type in
long-winded calculations. To use a function, just type in the function keyword and the parameters
on which the function will operate. The most common built-in functions are:

SUM – add numbers in a range of cells.


AVERAGE – computes simple averages.
MIN – determines the smallest value.
MAX – determines the largest value.
MEDIAN – calculates the median.
ROUND – rounds the results of a formula to a specified number of decimal places.

WORKING WITH ARGUMENTS

Arguments can refer to both individual cells and cell


ranges and must be enclosed within parentheses. You can
include one argument or multiple arguments, depending on the
syntax required for the function. For example, the
function =AVERAGE(B1:B9) would calculate the average of the
values in the cell range B1:B9. This function contains only one
argument.
Multiple arguments must be separated by a comma. For
example, the function =SUM(A1:A3;C1:C2;E2) will add the values of all cells in the three
arguments.

Office 2019: PowerPoint Excel, and Access P a g e | 59


USING A FUNCTION

In the example below, it is using a basic function to calculate the average price per unit for a
list of recently ordered items using the
AVERAGE function.

1. Select the cell that will contain


the function. In our example,
we'll select cell C11.
2. Type the equals sign (=) and
enter the desired function
name. In our example, we'll
type =AVERAGE.
3. Enter the cell range for the argument inside parentheses. In our example, we'll
type (C3:C10). This formula will add the values of cells C3:C10 and then divide that
value by the total number of cells in the range to determine the average.
4. Press Enter on your keyboard. The function will be calculated, and the result will
appear in the cell.

WORKING WITH UNFAMILIAR FUNCTIONS

If you want to learn how a function works, you can start typing that function in a blank cell to
see what it does. You can then type an open parenthesis to see what kind of arguments it
needs.

Office 2019: PowerPoint Excel, and Access P a g e | 60


UNDERSTANDING NESTED FUNCTIONS

Whenever a formula contains a function, the function is generally calculated before any other
operators, like multiplication and division. That is because the formula treats the entire
function as a single value—before it can use that value in the formula, it needs to run the
function. For example, in the formula below, the SUM function will be calculated before
division. Let us look at a more complicated example that uses multiple functions:

=WORKDAY(TODAY(),3)

Here, we have two different functions working together: the WORKDAY function and the
TODAY function. These are known as nested functions, since one function is placed,
or nested, within the arguments of another.

As a rule, the nested function is always calculated first, just like parentheses are performed
first in the order of operations. In this example, the TODAY function will be calculated first,
since it's nested within the WORKDAY function.

Class Exercise 2 – SUM Function

1. Open a new workbook and enter information (numbers) in cell range C2 to F8.
2. Click in cell C9 and type =SUM(C2:C8) and press Enter. This will tell Excel to add up the sum
of all the cells from C2 to C8.
3. Click in cell D9 and Type =SUM(and then select cells D2 to D8.
4. You can type the right bracket, but if you do not Excel will put it in for you. Press Enter to
complete the function. It should look like this =SUM(D2:D8)

Note If you want to add together more than one group of cells, you can separate each cell range
with a comma.
E.g. =SUM(C2:C8;E2:E8;G2:G8) This would add cells C2 to C8 and E2 to E8 and G2 to G8

Office 2019: PowerPoint Excel, and Access P a g e | 61


Class Exercise 3 – Using the AutoSum Tool

Since the SUM function is used so often, a special tool has been provided to make it easy to use.

1. Click in cell E9.


2. Click the AutoSum icon on the Ribbon bar (It is found on the Home
and Formulas tabs). Excel will create a SUM function referring to the
cells above. Excel will assume the cells above are the ones to be
added together. These cells will remain selected in case you would
rather select a different group of cells. If there are no numbers in
the cells above, the cells to the left will be used. Otherwise, the
nearest group of cells will be selected.
3. Press Enter to confirm that the correct cells are selected and
complete the function. The function should look like: =SUM(E2:E8)
4. You can also use the AutoSum tool by selecting the cells to be added
first.
5. Select cells F2 to F8.
6. Click the AutoSum icon. A SUM function will be automatically created based on the cells
you selected. The AutoSum icon can also be used to create other common functions such
as AVERAGE and COUNT.
7. Click in cell G9.
8. Click the arrow next to the AutoSum icon. A list of common functions will be displayed.
9. Click on Average. An AVERAGE function will be created in the selected cell. Notice that it
is written the same as a Sum function.
10. Check that the function reads =AVERAGE(G2:G8) and press Enter to complete the function.
11. Save the changes to the workbook, give it a name of your choice.

Class Exercise 4 – Using Functions in a Table

1. Select the worksheet named Joe Bloggs.


2. Add new labels in Column A as shown to the right.
3. Click in cell F6
4. Click the AutoSum icon.
5. Make sure cells B6 to E6 are selected and press Enter to
complete the function.
6. Use the fill handle to copy the function down through to cell F16. When a formula is copied to
other cells, the cell references should change for each cell.
7. Click in cell B15 and then click the arrow next to the AutoSum icon and click on AVERAGE.
8. Make sure cells B6 to E6 are selected and press Enter to complete the function.
9. Use the fill handle to copy the formula across to cell F15.
10. Click in cell B16.
11. Click the arrow next to the AutoSum icon and click on MAX.

Office 2019: PowerPoint Excel, and Access P a g e | 62


Notice that the function has selected all of the cells above including the average cell
which don’t need to be selected.

12. While these cells are still highlighted,


select cells B6 to B14 and press Enter.
The formula in cell B16 should be
=MAX(B6:B14).
13. Use the fill handle to copy the formula
across to cell F16.
14. Try completing the Lowest mark cells in
row 17 yourself by using the MIN
function.
15. Use a Count Numbers function in cell B18 to show the number of students.

Excel Text Functions: LEFT, RIGHT, MID and LEN

Microsoft Excel offers many effective functions to allow us to manipulate data. Three of the most
widely used of those are the ‘LEFT’, ‘MID’, and ‘RIGHT’ functions. Separating what you need from
what you don’t need the ‘LEFT’, ‘MID’, and ‘RIGHT’ functions are designed to allow us to take out
substrings from a single string of data based on that substring’s relative position within the source
string. The syntax for the ‘LEFT’ and ‘RIGHT’ functions are the same while the ‘MID’ function
contains one additional parameter.

Syntax for the ‘LEFT’ Function

There are two parameters/arguments within the function: text and num_chars.

=LEFT(text;[num_chars])

The text parameter simply refers to the actual string up for manipulation, most commonly just
the cell reference that contains the string. The num_chars parameter refers to the number of
characters from the left side of the string you want to extract.

=LEFT(“excel”;2)

For instance, if you selected “2” for num_chars and your string was the word “excel”, your
returned value would be “ex”.

Office 2019: PowerPoint Excel, and Access P a g e | 63


Syntax for the ‘RIGHT’ Function

=RIGHT (text;[num_chars])

Arguments
• text: The text from which to extract characters on the right.
• num_chars: The number of characters to extract, starting on the right. Optional, default =
1.

Number formatting is not part of the form and will not be extracted or counted. The Excel RIGHT
function extracts a given number of characters from the right side of a supplied text string. For
example, RIGHT("apple",3) returns "ple". Use the RIGHT function when you want to extract
characters starting at the right side of text. RIGHT will extract digits from numbers as well.

The above RIGHT Formula in Excel will return “tring”

LEFT and RIGHT Functions in Use

1. In this case for row 2 in the example, we are looking for the first 2 characters of the original
string which is in cell A2.
2. Therefore, our first parameter (text) is “A2”.
3. Then our next parameter, num_chars, is the number of characters from the leftmost character
in the string we would like to take out.
4. In this case, we want the first 2 characters of the original string so or formula will be
“=LEFT(A2;2)” which gets us “ex”.

Office 2019: PowerPoint Excel, and Access P a g e | 64


5. “The ‘RIGHT’ function works exactly the
same as ‘LEFT’ syntactically except now
we are selecting the number of
characters from the end of the string
we want to extract from the original
string.”
6. You can see in the figure above in row
3 that the formula “=RIGHT(A3;2)” returns the substring “el” since it is the last two characters
of the string “excel” found in cell A3.

‘MID’ Function

The ‘MID’ function is designed to parse out a substring from neither the left or right ends of a
string, but rather a middle section of string based on the same two parameters in addition to a
third.

MID formula in Excel has three compulsory parameters i.e. text, start_num, num_chars.

Compulsory Parameters

• text: it is text from which you want to extract the substring.


• start_num: the starting position of the substring.
• num_chars: the numbers of characters of the substring.

1. Using our earlier example of the word “excel” as the string, each letter can be thought of as a
numeric position starting with 1 through 5 in this case of a string of 5 characters.
2. So if you wanted to parse out the middle most character of “excel”, you would select “3” as
your start number and “1” as your number of characters. Assuming the data string is in cell A2,
the formula would be “=MID(A2;3;1)” and our result would be the substring “c”.

In this MID Formula example, we are fetching the substring from the given text string by using the
MID formula in excel =MID(B3;2;5) it will fetch the substring from 2 character and 5 letters from
2nd position and output will be as shown in the second column.

Office 2019: PowerPoint Excel, and Access P a g e | 65


Combining ‘LEFT’, ‘MID’, and ‘RIGHT’.

1. Below, column A contains string data for some dates. We can use the ‘LEFT’ function to extract
the first three characters of the source string which in this case happens to be the day of the
week.
2. Taking the 4 characters on the right of the source string gives us the year and if we use the
‘MID’ function starting with the fifth character of the source string and extracting the next 6
characters, we can parse out the month and day.

This example demonstrates how easy it is to see how effective the ‘LEFT’, ‘MID’, and ‘RIGHT’
functions can be in a situation like this.

FUNCTION: LEN (LENGTH)

All the ‘LEN’ function does is return the length of a string in a cell and able to count letters,
numbers, special characters, non-printable characters, and all spaces from an Excel cell. In simple
words, LENGTH Function is used to calculate the length of a text in an Excel cell.

For instance, in our earlier example where we were deconstructing substrings from the string
“Excel”, the ‘LEN’ function applied to this string would give us 5.

THINGS TO REMEMBER WHEN USING THE LEN FUNCTION IN EXCEL

1. Counts how many characters there are in some


string. It can be used on date and numbers.
2. Does not include formatting length. For
example, the length of “100” formatted as
currency “BWP100.00” is still 3).

Office 2019: PowerPoint Excel, and Access P a g e | 66


3. If the cell is empty then Length function return 0 as output. As shown in row three and six
empty string has 0 lengths.

Using Trim Function


Trim function removes leading and trailing spaces from given text.

Syntax: =TRIM(text)

Example: Suppose we have this text: “ I got my qualification at BUAN “. You do not want leading
and trailing spaces. Them you can use trim as below:

In cell C2 type: = TRIM (“ I got my qualification at BUAN “)

Results:

Spaces and the beginning and end of the sentence removed

Using an IF Function

IF functions can be useful if you want an Excel formula to select from 2 different answers based
on criteria you specify. In our grades example, we can use an If function to say a student has passed
if their mark was over 50 and fail if their mark wasn’t over 50. The IF function has 3 sections with
a semi-colon between each section as shown below.

=IF(condition to test; answer if condition is true; answer if condition is false)

Office 2019: PowerPoint Excel, and Access P a g e | 67


Function Wizard

You can access all the available functions in


Excel using the Function Wizard.

1. Select the cell where the function will


be placed and click the Function Wizard
button on the formula bar
2. Another way of starting the Function
Wizard:
i. Click on the drop-down arrow
next to the Autosum icon button.
ii. You will first see the commonly
used functions in Excel, and at
the bottom of the menu, the
More Functions option.
iii. Clicking on More Functions will give you an alphabetical and categorical listing of all
available functions in Excel.

From the Insert Function dialog box, browse through the functions by clicking in the Function
category menu and selecting from the Function name choices. As each function name is
highlighted a description is provided below the Function name box.

Clicking OK to select the function opens the Function Arguments dialog box, which allows you to
choose the cells that will be included in the function.
1. As in the last previous function, we can type the cell addresses in the necessary argument
boxes.
2. We can also enter the cells using the point mode (i.e., the left mouse button).
i. Click and drag across a group of cells to enter a range of cells addresses.
ii. Use the Ctrl key and mouse to enter a union of cells addresses.
3. Excel may automatically select cells for you, but you can delete those selected cells from
the argument box and enter the desired cell addresses.
4. Click OK when all the cells for the function have been entered into the necessary argument
boxes.

Class Exercise 5: Formulas and Functions

1. We are still working with Joe Bloggs worksheet. Click in cell G5 and enter the heading
Pass/Fail. Enter the following IF function.

=IF(F6>=50;"Pass";"Fail")

2. The first part of the formula checks to see if the number in cell F6 is greater than 50 or equal
to 50. The = sign is important. If it was left out then someone who scored exactly 50 wouldn’t
be included.

Office 2019: PowerPoint Excel, and Access P a g e | 68


3. The second section says that if this test condition is true, the text Pass will be displayed for the
answer.
4. Note that where text is used in a formula, it must be enclosed in quotation marks. The third
section specifies the answer (Fail) if the test condition is not true.
5. When the IF function has been entered, use the fill handle to copy the formula down to cell
G14. There should be 7 passes and 2 fails.
6. All other functions can be entered and executed in a similar fashion.

COPYING A FORMULA

Using the Fill Handle

1. Select the cell that contains the formula, then position the mouse pointer over the lower-right
corner of the cell until the black cross (+) appears.
2. Drag the fill handle over the cell or cells to which you want to copy the formula, then release
the mouse button.

Using Traditional Copy and Paste

1. Select the cell that contains the formula, and on the Edit menu, click Copy.
2. Select the cell or cells that you want to copy it to.
a. To copy the formula and any formatting, on the Edit menu, click Paste.
b. To copy the formula only, on the Edit menu, click Paste Special, and then click Formulas.

ROUND FUNCTIONS

ROUND Function

This function rounds a number to the specified number of digits. For example, ROUND(3.18302;2)
returns the output value as 3.18

Syntax: =ROUND(number, num_digits)

Argument Description

Number – The input number that needs to be rounded.

Class Exercise 6: Round Function

Create the following as it appears below and calculate the Round function and use an appropriate
function to calculate the total for Sales and Commission.

Office 2019: PowerPoint Excel, and Access P a g e | 69


MROUND Function
This function returns a number rounded to the given multiple. It will round the number to the
nearest multiple (“±” to the multiple value) of the given input value.

Syntax: =MROUND(number; multiple)

Argument Description

Number – The input number that you need to round.


Multiple – The multiples by which you want to round the number.

The number and multiple must have the same sign, else it returns #NUM! Error value.
If you use any non-numeric values such as letters or special characters, it returns #VALUE! Error.

Office 2019: PowerPoint Excel, and Access P a g e | 70


WEEK 6: ADVANCED EXCEL FUNCTIONS
COUNTIF FUNCTION

Used for counting cells within a specified range that meet a certain criterion, or condition.

Syntax: =COUNTIF(range,criteria)

Class Exercise 1: CountIF Function

Let us count all students who failed. That is writing a formula that will count all students who got
50% or above.

1. Use BEC 2022 BGCSE file workbook from ICT122 Eduhub Page onto the desktop.
2. Select the Totals worksheet.

CRITERIA FORMULA EXAMPLE DESCRIPTION

Count if greater =COUNTIF(A2:A10,">5") Count cells where value is greater


than than 5.
Count if less than =COUNTIF(A2:A10,"<5") Count cells with values less than 5.

Count if equal to =COUNTIF(A2:A10,"=5") Count cells where value is equal to 5.


Count if not equal =COUNTIF(A2:A10,"<>5") Count cells where value is not equal to
to 5.
Count if greater =COUNTIF(C2:C8,">=5") Count cells where value is greater
than or equal to than or equal to 5.
Count if less than =COUNTIF(C2:C8,"<=5") Count cells where value is less than or
or equal to equal to 5.

3. In cell J2, type =COUNTIF (B3:B22,">=50")

a. Now let’s count those students who failed (below 40%)

4. In cell J4, type = COUNTIF(B3:B22,"<40")

Office 2019: PowerPoint Excel, and Access P a g e | 71


COUNTIF Formulas with Wildcard Characters (Partial Match)

Count cells beginning or ending with certain characters. You can use either wildcard character,
asterisk (*) or question mark (?), with the criterion depending on which exactly result you want to
achieve. In case your Excel data include several variations of the keyword(s) you want to count,
then you can use a wildcard character to count all the cells containing a certain word, phrase or
letters as part of the cell's contents.

Suppose we want to count those whose surname is Brown:

• On cell J5, type =COUNTIF(B3:B22;"*Brown")

COUNTIF for Blank and Non-Blank Cells

These formula examples demonstrate how you can use the COUNTIF function in Excel to count
the number of empty or non-empty cells in a specified range.

COUNTIF not Blank

Using COUNTIF function for counting non-blank cells in Excel like this one:

=COUNTIF(range,"*")

If you need a universal COUNTIF formula for counting all non-blank cells in a specified range, here
you go:

=COUNTIF(range,"<>"&"")

COUNTIF Blank

If you want the opposite, i.e. count blank cells in a certain range, you should adhere to the same
approach - use a formula with a wildcard character for text values or another one (with the ""
criteria) to count all empty cells.

Formula to count cells not containing any text: =COUNTIF(range,"<>"&"*")

=COUNTIF(C2:C11, "") returns the number of all empty cells in the range C2:C11.

COUNTIFS Function

The COUNTIFS function applies criteria to cells across multiple ranges and counts the number of
times all criteria are met.

Syntax: =COUNTIFS(criteria_range1,criteria1,[criteria_range2, criteria2]…)

The COUNTIFS function syntax has the following arguments:

Office 2019: PowerPoint Excel, and Access P a g e | 72


• criteria_range1 Required. The first range in which to evaluate the associated criteria.
• criteria1 Required. The criteria in the form of a number, expression, cell reference, or
text that define which cells will be counted. For example, criteria can be expressed as 32,
">32", B4, "apples", or "32".
• criteria_range2, criteria2, ...
• Optional. Additional ranges and their associated criteria. Up to 127 range/criteria pairs are
allowed.

Important: Each additional range must have the same number of rows and columns as
the criteria_range1 argument. The ranges do not have to be adjacent to each other.

In cell J6: Count all students of passed CA but failed examination

SUMIF Function

You use the SUMIF function to sum the values in a range that meet criteria that you specify.

Syntax: =SUMIF(range, criteria, [sum_range])

For example, suppose that in a column that contains numbers, you want to sum only the values
that are larger than 5.

You can use the following formula: =SUMIF(B2:B25,">5")

Class Exercise 2: SumIf Function

Do the following in Insurance sales worksheet:

• In B25 through to M25, compute total sales of all consultants every month.
• In B26 through to M26, compute total sales of all over performers for each month, given
that an over performer is the one who sold more than BWP 3000.00 per month.
• In B27 through to M27, compute total sales of all under performers for each month, given
that an under performer is the one who sold less than BWP 1000.00 per month.
• In B28 through to M28, compute total sales of all normal performers for each month,
given that a normal performer is the one who sold at least BWP 1000.00 but less than
BWP 3000.00 per month.
• In B29 through to M29, compute total sales of all those whose surname is White for each
month.

The SUMIFS function,

Adds all its arguments that meet multiple criteria.

Syntax: =SUMIFS(sum_range, criteria_range1,criteria1,[criteria_range2, criteria2], ...)

Office 2019: PowerPoint Excel, and Access P a g e | 73


Class Exercise 3: SUMIFS Function

In cell B35, compute total January sales for those whose surname is Brown and over performed
in February.

LOOKUP FUNCTIONS

Lookup functions are a bit like an IF function. They allow you to create a formula that will choose
from several different answers based on information in a table. Vertical and Horizontal lookup
(VLookup & HLookup) functions are available for use in Excel. Vlookup and Hlookup functions
are all related. The following table lists the differences between these functions

Lookup Can lookup values vertically or horizontally;


The data to be searched (in the lookup row or column) must be ordered;
If an exact match is not found, the Lookup function will match the closest
value below the lookup value.
Vlookup Performs a Vertical lookup;
The user can decide what the function should do if an exact match is not found -
either return an error or match the closest value below the lookup value.
Hlookup Performs a Horizontal lookup;
The user can decide what the function should do if an exact match is not found -
either return an error or match the closest value below the lookup

VLOOKUP AND HLOOKUP

=VLOOKUP(Value you want to look up, range where you want to lookup the value, the column
number in the range containing the return value, Exact Match or Approximate Match – indicated
as 0/FALSE or 1/TRUE)

=HLOOKUP(Value you want to look up, range where you want to lookup the value, the row
number in the range containing the return value, Exact Match or Approximate Match – indicated
as 0/FALSE or 1/TRUE)
Syntax:

=VLOOKUP(lookup_value,table_array,column_index_num,[range_Lookup])

=HLOOKUP( lookup_value,table_array,row_index_num,[range_lookup] )

Office 2019: PowerPoint Excel, and Access P a g e | 74


Like an If function, a Lookup function The cell the function is checking, in this case the
has different parts. The sections of a student mark.
lookup function are described below.
Lookup value
Table array The cells the answers are coming from - our table of
grade cut-offs
Column index The column in the array that the answer will come
from. In our case, the function will match the
student grade with a number in the first column of
the array, then it will check the second column to
find the matching grade, so the second column is
the column index.
Range lookup If the function does not find an exact match in the
table array, putting true in this section will mean
that it will use the closest match instead.
Class Exercise 4 – Vertical Lookup

In the example below, we will use a vertical lookup function to


create a formula which checks a student’s mark and shows what
their grade will be.

1. Using the Joe Bloggs worksheet in the Week 5 Practical –


Formulas and Functions workbook if it is not already open. The
first thing we will need to do is create the table that will contain
the grade cut-off points.
2. Click in cell K6 and enter a zero and complete the information in
cells K6 to L10 as shown to the right.
3. Click in cell H5 and enter the text Grade.
4. Click in cell H6. This is where we want the first grade to go.
5. Enter the following formula. =VLOOKUP(
6. Click on cell F6 (the cell with the first student’s mark).
7. Type a comma to end the first section and then select the grades cut-off table (which should
be cells K6 to L10.
8. Press F4 to make sure this section uses absolute references ($K$6:$L$10). When we copy the
function down for the other students, we want to make sure it is still correctly referring to the
cells with the grade cut-off marks.
9. Type another comma and then the number 2 and type another comma and then type true.
10. Type a closing bracket and then press Enter to complete the formula. The completed formula
should be =VLOOKUP(F6,$K$6:$L$10,2,TRUE).
11. With cell H6 selected, move your mouse over the Fill Handle.
12. Double click on the fill handle. The contents of the cell will be copied down until a blank cell is
detected to the left. This can be a quick way of using the AutoFill function in a table. If your
lookup table goes horizontally instead of vertically then you can use a horizontal lookup
function. It works the same except that you type HLOOKUP instead of VLOOKUP and save and
close the file.

Office 2019: PowerPoint Excel, and Access P a g e | 75


DELETE A FORMULA

When you delete a formula, the resulting values of the formula are also deleted. However, you
can instead remove the formula only and leave the resulting value of the formula displayed in the
cell. To delete formulas along with their resulting values, do the following:

1. Select the cell or range of cells that contains the formula.


2. Press DELETE.

To delete formulas without removing their resulting values, do the following:


1. Select the cell or range of cells that contains the formula.
2. On the Home tab, in the Clipboard group, click Copy.
3. On the Home tab, in the Clipboard group, click the arrow below Paste, and then click Paste Values.

USE THE RANK AND PERCENTILE TOOL FROM THE ANALYSIS TOOLPAK

The Analysis ToolPak

The Analysis ToolPak is an add-in for Microsoft Excel that comes with Microsoft Excel. An add-
in is simply a hidden workbook that adds commands or features to Excel.

Load the Analysis ToolPak

The Analysis ToolPak is a Microsoft Office Excel add-in program that is available when you install
Microsoft Office or Excel.

To use the Analysis ToolPak in Excel, however, you need to load it first.

1. Firstly, we need to load the Analysis Group.


2. Go to File menu, and then click Options.
3. Click Add-Ins, and then in the Manage box, select Excel Add-ins.
4. Click Go.
5. In the Add-Ins available box, select the Analysis ToolPak check box, and then click OK.

Office 2019: PowerPoint Excel, and Access P a g e | 76


Tip: If Analysis ToolPak is not listed in the Add-Ins available box, click Browse to locate it.

After you load the Analysis ToolPak, the Data


Analysis command is available in the Analysis group
on the Data tab.

To illustrate how to use this tool, we will work through


an example. In this example, there is a class of 30
students. Having just got their latest results and want
to rank them and assign them grades based on their
ranking within the class. The top 10% get an A, the
next 20% get a B, the next 20% get a C and the
remainder get a D grade.

Adding the Analysis ToolPak in Excel

Before using the tool, we need to ensure that the Analysis ToolPak is present in Excel. The ToolPak
can be found on the Data tab, in the Analysis group and is accessed via the Data Analysis button.

Using the Rank and Percentile Tool in Excel

Now that we have added the Analysis


ToolPak, select the Data Analysis
button and select Rank and Percentile
as shown below.

The tool itself it is quite


straightforward and easy to use. Select
the Rank and Percentile worksheet.

1. First select the Input Range


2. If your data is in columns, leave Grouped By as Columns (otherwise select Rows)
3. If you have labels for your columns, then select Labels in first row.

Office 2019: PowerPoint Excel, and Access P a g e | 77


4. Lastly, select your Output options, select Output Range to place it in a specific place on your
worksheet or select New Worksheet Ply or New Workbook depending on your preference
(we placed the tool’s results next to the original data in the example we are working through
today). Click OK and Excel will create your Rank
and Percentile table.

You can see the output from the tool. Excel has
ranked every student and given them their exact
percentile (the Percent column), however, rather
than using the students’ names, there is a column
called Point, which is the row number of each
student.

Have a look at the Point column into a column


containing the student’s name, there is a need to
turn to the MATCH and INDEX function.

Using the MATCH and INDEX function in Excel to


convert the results in the Point Column created by
the Rank and Percentile Tool to the actual.

These two functions work in tandem to convert the results in the Point column to the student’s
name.

N.B. The values in the lookup array must be sorted in descending order, i.e. from
largest to smallest.

MATCH FUNCTION

The syntax for the Excel MATCH function is as follows:


Syntax: =MATCH(lookup_value, lookup_array, [match_type])

The Match Function returns Relative Position of Value

Example: = MATCH (9,A1:A4) returns 2

The MATCH function looks for the number in the Point column and then finds its exact match in
the column labelled Student No.

Office 2019: PowerPoint Excel, and Access P a g e | 78


INDEX FUNCTION

Returns the value or reference to the value from a table or range:

Syntax: =INDEX(array, row_num, [column_num])

Here is a very simple explanation of each parameter:

• array - this is a range of cells that you want to return a value from.
• row_num - the row number in array from which you want to return a value. If omitted, the
column_num is required.
• column_num - the column number in array from which you want to return a value. If omitted,
row_num is required.

If both row_num and column_num parameters are used, the INDEX


function returns the value in the cell at the intersection of the
specified row and column.

In the example on the right screen the formula:

=INDEX(A1:B5,2) returns 0.75

Class Exercise 5: Using IF Function

1. Using the BEC 2022 BGSCE.xlxs calculate the final adjusted mark using the following
information.
a. If the final mark is less than 40% adjust the final mark by 20%
b. If the final mark is less than 50% adjust the final mark by 15%

MAKE SURE YOU HAVE COMPLETED CLASS EXERCISES 5 ABOVE AND IT


HAS BEEN CHECKED BY THE INSTRUCTOR BEFORE MOVING TO THE NEXT
PART OF THE LAB.

Office 2019: PowerPoint Excel, and Access P a g e | 79


UNDERSTANDING EXCEL ERROR VALUES AND HOW TO FIX THEM

1. ######

Problem: The column is not wide enough to display all the characters in a cell.
Fix: Extend the width of the column.

2. # Div/0!

Problem: Excel displays this error when a number is divided either by zero (0) or an empty cell.
Fix: Change the divider to a value that is not equal to 0.

3. #Name?

Problem: The text in a formula is not recognised by Excel. This is caused by misspelling the function
names. For instance =SUM(A1:A7) will result in the #Name? error.
Fix: Correct the error by entering =SUM(A1:A7).

4. #Value!

Problem: This error will be displayed if the formula includes cells that contain different data
types. =B1(85) + B2(75) +B3(data) will result in the #Value! error message.
Fix: Replace B3(data) with a numeric value and the error will be corrected.

5. #REF!

Problem: The error will be displayed when a cell reference is not valid. Deleting cells that were
referred by other formulas will cause this error.
Fix: Refer the cells to the correct ranges and the error will be corrected.

6. #NUM!

Problem: The formula or function contains invalid numeric values.


Fix: Using $ ,% symbols with the number can result in this error, so avoid using these.

7. #NULL

Problem: Excel displays this error when you specify an intersection of two areas that do not
intersect (cross). The intersection operator is a space character that separates references in a
formula. =SUM(A1:A2 C3:C5) returns the #NULL error because the two ranges do not intersect.
Fix: =SUM(A1:A2, C3:C5) will return the correct reference.

Office 2019: PowerPoint Excel, and Access P a g e | 80


WEEK 8: CHARTS AND GRAPHS

OVERVIEW

How to use Excel to create charts. The standard charts we are going to create are bar, pie and line
charts. We will also look at Formatting Numbers and database commands in Excel.

OBJECTIVES

• Database Commands
➢ Data Form
➢ AutoFill
➢ Data Sort
➢ AutoFilter
• Creating a Chart
• Modifying Charts
➢ Moving a Chart
➢ Resizing a Chart
➢ Changing a Chart Feature
➢ Deleting a Chart
➢ Printing a Chart

DATABASE COMMANDS

DATA FORM

Provide Excel with the titles you want on the worksheet, and then add information record by
record.

Firstly, do the following:

Make the Form available on the Ribbon if it is not there already. Go to File menu, click Options,
and in left pane click Customize Ribbon. In right pane select All Commands from Choose
commands from drop-down options and look for Form command. Now from left pane, select
Home and click New Group, new group will be added to Home tab, click Rename and change its
name to Form, and then click Add >> button to add Form command to newly created group. Click
OK to close Excel Options dialog.

• Type the titles on to the first row of the worksheet as indicated in the figure below.
• Highlight the title heading.
• Go to Form menu on the Home tab and choose Form.
• Click OK to confirm that the top row of your selection is the header row.
• A form appears with the titles as the file names on it.

Office 2019: PowerPoint Excel, and Access P a g e | 81


• Enter data into your records.

Class Exercise 1: Data Form

Enter the following data using a form. (Do not retype the titles again)

ID # Surname First Name Test 1 Test 2 Test 3


203000620 Moses Victor 65 48 68
203000760 Ramsey Aaron 87 90 92
203000040 Oliviera Linah 78 88 65

Form AutoFill

It allows you to fill a specified range with a sequence of numbers or text.

Activity:

1. Type in the first two values in the series in the first two cells of your list.
2. Select the cells in which you have just placed your values.
3. Move the pointer to the fill handle (small dark box in the bottom right corner of the cell
border)
4. Click and drag your mouse down over the cells you want to AutoFill to fill in.
5. Release the mouse and AutoFill will fill in the cells that you selected.

Data Sort

This rearranges data within a column.

Activity:

1. Select the database information you want to sort. NB: Select the whole record because we
want the records to remain intact after sorting. If you don’t choose the whole record, Excel
will ask you if you want to expand the sort or not.
2. Go to Editing menu under Home tab and choose Sort & Filter.

Office 2019: PowerPoint Excel, and Access P a g e | 82


3. From here you can choose to sort without specifying which column to use (Excel will use
the first column), or you can choose to customize your Sort so that you choose which
column to use for sorting.
4. From the box that appears, choose which fields you want to sort, and the kind of sort, i.e.
whether by ascending or descending order.
5. Click OK.

Class Exercise 2: Sort and Filter

Sort the data alphabetical using student surname.

AutoFilter

This allows you to define a criterion, and then use it to find, select and delete records in a database.

Activity:

1. Select all the records including the titles.


2. Go to Editing menu under Home tab, choose Sort & Filter and then choose Filter.
3. Small arrows appear in each cell containing a field title.
4. Choose the arrow in the cell with the data you are working on and choose Number Filters.
5. From the menu that appears choose how you want to filter.
6. If you choose Custom Filter (at the very end of that menu), you will get the Custom
AutoFilter dialog box.
7. In that box, click on the first row to view your options. Choose appropriately.
8. Click OK.

Use AutoFilter command to display all students who got between 40 and 50
inclusive in Test 1.

CHARTS

It can often be difficult to interpret Excel workbooks that contain a lot of data. Charts allow you to
illustrate your workbook data graphically, which makes it easy to
visualize comparisons and trends. Charts help you visualize your data in a way that creates
maximum impact on your audience.

Types of Graphs

Excel has several different types of charts, allowing you to choose the one that best fits your data.
To use charts effectively, you will need to understand how different charts are used.

Office 2019: PowerPoint Excel, and Access P a g e | 83


Column charts use vertical bars to represent data.
They can work with many different types of data, but
they are most frequently used for comparing
information.

Line charts are ideal for showing trends. The data


points relate to lines, making it easy to see whether
values are increasing or decreasing over time.

Pie charts make it easy to compare proportions. Each value is shown as a slice of the pie, so it is
easy to see which values make up the percentage of a whole.

Bar charts work just like column charts, but they use horizontal bars instead of vertical bars. Area
charts are like line charts, except the areas under the lines are filled in.

Surface charts allow you to display data across a 3D landscape. They work best with large data
sets, allowing you to see a variety of information at the same time.

In addition to chart types, you will need to understand how to read a chart. Charts contain several
different elements, or parts that can help you interpret the data.

Office 2019: PowerPoint Excel, and Access P a g e | 84


Creating Column Chart

Copy the worksheet information used when creating the form into a new workbook as it and save
it on the desktop named Graphs.

Let us use the data to create the chart as shown below.

ICT122 2021/2022
120
100
80
MARKS

60 TEST 1
40 TEST 2
20
TEST 3
0
Kago Thabiso Olerato Tebogo Dikabo

STUDENT NAME

1. Select the cells you want to chart – in this case select data from first name to Test 3 (C7:F12),
including the column titles and row labels. These cells will be the source data for the chart.
From the Insert tab, click the desired Chart command. In our example, we will select Column.
Choose the desired chart type from the drop-down menu.

The selected chart will be inserted in the worksheet.

CHART LAYOUT AND STYLE

Once a chart has been created, there are several things you may want to change about the way
your data is displayed. It is easy to edit a chart's layout and style from the Design tab. Excel allows
you to add chart elements—such as chart titles, legends, and data labels—to make your chart
easier to read.

To add a chart element,

Office 2019: PowerPoint Excel, and Access P a g e | 85


• Click the Add Chart Element command on the Design tab, then choose
the desired element from the drop-down menu.
• To edit a chart element, like a chart title, simply double-click the placeholder and
begin typing.

Class Exercise 2: Chart

Insert pie chart and line graphs using the data from the workbook you created.

MODIFYING A CHART

Moving a Chart

1. Move the pointer anywhere into the chart (do not point to any chart feature).
2. Press and hold down the left side of the mouse.
3. Drag to your desired location.

NB: if you don’t want the chart as an object of a sheet, but rather as a new sheet on
its own, right-click on the chart and choose move chart. You will get the following
dialog box. Choose where you want to place the chart.

Resizing a Chart
Changing a Feature/Properties
1. Select the chart you want to resize
2. Move your pointer to any of the little, 1. Select the chart
small squares around the chart 2. Choose either Design, Layout or Format
3. Drag to change the size. from the Chart Tools
3. Change the features as you wish.
OR

Office 2019: PowerPoint Excel, and Access P a g e | 86


1. Move the pointer to the chart area
2. Right Click
3. From the short menu that appears, choose whatever you want to modify.

NB: Right-clicking the chart area will give you only limited options, so it’s better
to use Chart Tools from the Ribbon.

Deleting a Chart

1. Select the chart


2. Press the Delete key from the keyboard

Printing a Chart

PRINTING WILL NOT YIELD ANYTHING AS THERE IS NO PRINTER CONNECTED TO THE LAB
COMPUTERS.

1. Select the chart


2. Go to File menu
3. Choose Print

Class Exercise 3: Creating Charts

Inventory of Elisa’s Bead Collection

Express the category, colour, size and quantity of the beads in Elisa’s bead collection.

100 ivory‐coloured freshwater pearl beads, 3 mm


25 Japanese square beads, red, 3 mm
25 Japanese square beads, blue, 3 mm
13 purple Swarovski 5 mm bicones
30 pink Swarovski 3 mm bicones
15 plastic neon green 8 mm pony beads
3 pink faux pearl beads, 4 mm
26 round turquoise beads, 8 mm
2 Venetian glass beads, bicones, 6 mm, clear
18 clear Swarovski 5 mm bicones

Now answer the following questions, using as many different Excel commands as possible:

1. What is the total number of beads in Elisa’s collection?

2. How many bicone beads are in the collection?

87 | P a g e
3. What is the mean, median and mode of the bead size within this collection?

4. Create a chart (i.e. graph) to illustrate the spread of the bead collection. Choose any
three of the charts.

Simple 3-Column Balance Sheet

Capture the following information in a 3‐column balance sheet, showing columns for
“Budget”, “Expense” and “Balance”. Then, generate a chart illustrating the monthly expenses
up to December 2020.

Small Library Collection Budget

1. Budget from trustees at the beginning of the fiscal year: P100,000.


2. April 2020 expense: P20,000
3. May 2020 expense: P18,000
4. Monetary gift to the library collection, May 2020: P12,000
5. June 2020 expense: P8,000
6. July 2020 expense: P16,000
7. August 2020 expense: P14,000
8. September 2020 expense: P13,000
9. October 2020 expense: P3,000
10. November 2020 expense: P9,000
11. December 2020 expense: P8000.

Collection Budget Distribution

1. Capture the following information in a pie chart. Label each segment of the pie with their
Pula (BWP) value in addition to their percentage share of the total budget.
2. Total budget: P100,000
3. Book budget: 50% of total budget (of which a quarter is electronic)
4. Serials budget: 35% of total budget (of which half are electronic)
5. Audio visual budget: 10% of total budget
6. Taxes and shipping costs: 5% of total budget

MAKE SURE YOU HAVE COMPLETED THE ABOVE CLASS EXERCISES 3


AND HAS BEEN CHECKED BY THE INSTRUCTOR BEFORE MOVING TO
THE NEXT PART OF THE LAB.

88 | P a g e
WEEK 11 CREATING SIMPLE DATABASE
OBJECTIVES

By the end of the laboratory session, you should be able to do the following:

• Create a Database
• Save a Database
• Create and Save Tables/Relations
• Declare Primary Keys
• Edit Field Properties
• Enter Data in a Database

INTRODUCTION TO DATABASES

What is a Database?

A database is a structured repository for data. A database in manual terms is like a filing
cabinet, or more accurately to a series of filing cabinets. The overall purpose of such
repository is to maintain data for some set of organizational objectives. Most database
systems are built to retain the data required for running of the day-to-day activities.

An example is a university database that will be needed for such activities as recording
assessment of student courses. Therefore, we talk of a database as being a collection of data
structures. The data in the database should always be related.

The term database also usually implies a series of related properties: data sharing, data
integration, data integrity, data security, data abstraction and data independence. (These
properties are discussed in your presentation notes).

Basically, a database is effectively a set of data structures for organizing and storing data.

Relations - Restricted Set of Rules

A relation is a table which obeys a certain restricted set of rules:


1. Every table in a database must have a distinct name
2. Every column in a relation must have a distinct name
3. All entries in a column must be of the same kind. They are said to be defined on the
same domain
4. The ordering of columns in a relation is not significant
5. Each row in a relation must be distinct. In other words, duplicates rows are not
allowed in a relation.

89 | P a g e
6. The ordering of rows is not significant.
7. Each cell or column/row intersection in a relation should contain only a so-called
atomic value. In other words, multiple values are not allowed in the cell of a relation.

Primary Key

Each relation should have a primary key. This is to enforce property number 5 above, that
duplicate rows are forbidden in a relation. A primary key is one or more columns of a table
whose value is used to uniquely identify each row or record in a table. A primary key must
have the following properties:

1. It must be unique.
2. It must not be null.

Foreign Key

Foreign keys are the means of interconnecting the data stored in a series of disparate tables.
A foreign key is a column or group of columns of some table which draws its value from the
same domain as the primary key of some related table in the database.

DATABASE USING MS ACCESS

Starting MS Access

To start MS Access:

If MS office is installed to the computer you are using then,


1. Click the Start button on the Windows taskbar.
2. Look for MS Access button and click on it.

Creating a New Database

When MS Access is launched, a dialog box appears which provides you with several options;
see the figure below.

You can choose to create a Blank database, Blank web database, database from templates
or even Open an Existing database file.

90 | P a g e
"Create a New Database" dialog box

To create a new blank database double, click on Blank


database.

Type the name to give to your database under file name


textbox. In this case call it pet_med.

Now click the button next to File name textbox and specify
where you want to save your database. Let us save it under Desktop.

The window below appears.

Change the path to the desktop and click Save button.

Click create button to create the database.

91 | P a g e
Now an empty database has been created. The next part is to add objects, starting by adding
tables or relations.

Creating Tables/Relations

A table is a collection of data on the same subject


organized in fields and records. In MS Access many
tables of different layouts/designs may be included
in a single database file. There are several ways of
building tables in MS Access. In this course Design
View will be used in constructing tables.

Rows and Columns are referred to as records and fields. A field is more than just a column;
it’s a way of organizing information by the type of data it is. Every piece of information within
a field is of the same type.

Note: When you create database, by default it comes with one table called table1 as shown
on the diagram above. You should change the name of the table to any name in your database.

Let us add a table called Customer to the database.

Go to pet_med database you have created.

We are going to change the name of Table 1 to Customer.

1. Click on Table 1 to select


it.
2. Right Click the mouse
button or Click the View
Button under Views
group.
3. Then select Design View.
Change the name of the
table when prompted to.
4. The name of the table is
Customer and click OK. A new table is now added to the database windows like below
should be shown:

92 | P a g e
Now enter the names of the columns for
the table under Field Name and Data Type
(text, number, etc). The first field is
already added for you and defined as
primary key.
The Description is optional but it’s
important to explain your fields.

Enter Field Name and Field Type for the


Customer table as below:

Note: The first field name should be changed from ID to customer_id

Declaring a Primary Key

As already explained, a primary key is a field that will uniquely identify any record in a table;
therefore, each table must have a primary key. Once all the columns have been entered into
the design view a primary key for that table should be selected. In our example the
customer_id will be the primary key. It is already set for you. However, if it is not set then
follow the following steps:

To set a Primary key:

1. Select the field or fields


2. Click on the key icon (Primary key) under the Tools group or right click and choose
Primary key.

Modifying Field Properties

Field properties are set to control how the data in the fields can be entered and how the fields
behave. The properties allow you to:

1. Control how data can be entered in a field


2. How values are displayed
3. The range of values allowed
4. Default values
5. If a value must be entered

93 | P a g e
6. If a field is to be indexed.

The properties are associated with each field. See the table below for field properties.

Field Property Description Example

Field Size For text, numbers, and auto-number PublicationNo – 10


(counter) data type, field size sets the
maximum size for the data entered against
this field.
Format This property permits the user to customize PublicationDate – short date
the way data is displayed and printed. – DD/MM/YY
Decimal Places When using numbers, this property VolumeNo - 0
specifies the number of decimal places to be
displayed
Input Mask An input mask contains the type of isbnNo – 0-000-0000-00-
characters to be entered against each digit; L-letter
character of a field
Caption Permits a fuller description of the title to be PublicationTitle –
displayed for the field report Publication Title
Default Value A value automatically entered when a new VolumeNo – 1;
row is created IssueNo - 1
Validation Rule Allows user to specify domain constraints VolumeNo - >=1 OR <=100

Required Allows the user to not leave nulls against PublicationNo - Yes
field

Indexed Sets an index against a field AuthorNo in publication –


Yes

Class Exercise 1: Creating Tables

To edit the properties of a field, select the field and the properties will be displayed at the
bottom.

Let us start with customer_id field.

Click on customer_id to select it


Go to field properties and ensure that they
are as below:

94 | P a g e
Select all other fields and edit their properties as below:

Title Surname, name, Town and Country

Phone_Number (long integer) Value

Date of birth BirthDay

Month([Date of Birth]) “ ”& Day([Date of Birth])

1. Click save button to Save the table.


2. Let us add the second table to the database. The table is called pet

95 | P a g e
3. Click Create tab on the ribbon.

4. Then click Table Design Button


5. Now start by adding field names and types.
6. Ensure that Pet_id is set as a primary key

Remember, to set a Primary key:

Select the field or fields (in this case select Pet_id)


Click on the key icon (Primary key) under the Tools group or right click and choose Primary key.

Now edit field properties as below:

Pet_id

Pet_Name and Type Date of Birth

Year([Date_of_birth])

96 | P a g e
Medical Conditions

Saving a Table

1. Click the Save button


2. The name of the table (Pet) and click Ok

Alternatively

To save the table do Ctrl+S then a dialog box will appear for you to enter the name of the
table. Enter the name then hit save.

Add the third table as below:

Table name: Appointment

Fields

PLEASE ENSURE THAT THE THREE FIELDS (CUSTOMER_ID, TIME_OF_APPOINTMENT AND


DATE_OF_APPOINTMENT) ARE SET AS A PRIMARY KEY

97 | P a g e
Edit the field properties as below:

Appointment_id Customer_id

Time of appointment Appointment Date

Challenge: Add the validation rule to the Appointment date so that it returns error message
“Please enter today’s date or later date” if the user enters any date before today.

Save the table.

Entering Data

After creating the table, we now need to enter some data into it. To enter data we need to
view the table in Datasheet View.

1. Go to the Home tab


2. Click on View under Views group
3. Select Datasheet View.

98 | P a g e
Type data into the tables as below:

Customer Table

Pet Table

Appointment Table

Please note that the Date_of_Appointment should be recent dates.

Class Exercise 2: Creating Tables

Make sure you complete this exercise before the end of the lab session and save the file as it
will be used in the next two (2) practical sessions in Week 11 and 12.

99 | P a g e
Read the scenario below:

The Food Girls is a youth company that supply readily cooked food to their customers. They
supply variety of cooked food including chicken/beef burgers, quarters, pizzas, fried potato
chips, fizzy drinks, juices, coffees, etc. They sell their products from home. Customers place
an order by walking in, a phone call, WhatsApp message or Facebook chat line. Customer
order is recorded using an Excel file, then they prepare food and either deliver or customer
go to their home to collect. A customer may place an order at any time during the day. An
order may have variety of products. Each product may be ordered by different customers for
as long as is available. A customer may order as many times as he/she wishes per day or in
different days.

Create a new database and call it Food Girls based on the scenario above. The database
should be saved on the desktop and the move it to your One drive after adding all tables.

Class Exercise 3: Creating Tables

Create the following tables:

Table 1: CUSTOMERS

CUSTOMERS
Field Name Data Type Description
Primary Key CustNo Number Unique for each customer
CustName Text First name
CustSurname Text Last Name
ContactNo Number Telephone Number

Q: Why is CustNo set as Primary Key?

A:

Set the following properties for the CUSTOMERS Table:

CustNo CustName
Field Size Integer 20
Format General Number
Required Yes No
Indexed Yes (no duplicates) No

View the table in Datasheet View and enter sample data, of at least 10 records.

100 | P a g e
Q: Why is CustNo set as required and is indexed with no duplicates?

A:

View the table in Datasheet View and enter sample data, of at least 10 records.

Table 2: PRODUCTS

PRODUCTS
Field Name Data Type Description
Primary Key ProductNo Number Unique for each product
ProductName Text Name of product
QtyInStock Number Number of items in stock
Price Currency Unit Price in stock
RecordLevel Number Level at which to place order
RecordQty Number Amount normally in an order

Set the following properties for the PRODUCTS Table.

ProductNo ProductName QtyInStock Price RecordLevel RecordQty


Field Size Integer 35 Integer Integer Integer
Format General Currency General General
Number Number Number
Required Yes No No No No No
Allow Yes
zero
length
Indexed Yes (no No No No No No
duplicates)

View the table in Datasheet View and enter sample data, of at least 10 records.

Table 3: ORDERS

ORDERS
Field Name Data Type Description
OrderNo Number Enter Description
CustNo Number Enter Description

101 | P a g e
OrderDate Date/Time Enter Description

View the table in Datasheet View and enter sample data, of at least 10 records.

Q: Which field should be set as the primary key and why?

A:

Set the primary key, view the table in Datasheet View and enter the following data sample:

OrderNo CustNo OrderDate


1 3 12/01/2022
2 2 17/01/2022
3 4 25/02/2022
4 1 02/03/2022

Q: Why is the customer’s name not recorded in the ORDERS table?

A: Because it would be inefficient! i.e. you can easily find out the customer’s name from the
CUSTOMERS table if you know the customer’s number. (also, it could cause some
inconsistency in the database if you misspelled the customer’s name in one place but not in
another. Think about which customer name would be correct).

Q: Why is a customer number used instead of a name?

A:

Table 4: ORDERS DETAILS

ORDERS DETAILS
Field Name Data Type Description
ProductNo Number Enter Description
OrderNo Number Enter Description
Quantity Number Enter Description

102 | P a g e
Q: Which fields should be set as the primary key and why?

A:

Hint: Combinations of two key fields will always uniquely identify the product ordered on a
specific order.

Set the primary key, view the table in Datasheet View and enter the following data sample:

ProductNo OrderNo Quantity


2 1 5
5 1 2
3 1 6
1 1 7
2 2 5
6 2 4
5 2 5
3 3 2
4 3 1
1 4 3
3 4 2
4 4 2

Q: What kind of database are we building here?

A:

Bring the database to the next practical


session.

103 | P a g e
WORKING WITH CALCULATED FIELDS AND EXPRESSIONS

A calculated field is a field that derives its value by performing a function on values from
other table fields. It can also calculate values entered by hand. The field’s data only appears
for the duration of the query. It is not actually stored in the database tables. When a
calculated field is created in Access, almost any available function can be performed. You can
also use the query field to type data as values for the calculations.

Download the pet clinic database file from Eduhub on the ICT122 page Week 9 to your
OneDrive.

Text Fields

Open the database and go to Customer table. We are going to add calculated text field to the
table.

Add a new field called full_name to the table. The Data Type should be calculated.

Under Field properties, got expression and click on the button to the far right.

On the Expression Builder window, write an expression for fullname as below:

[custName] & [CustSurname]

or
Creating space between name and surname

[custName] & “ “ & [CustSurname]

Click OK

104 | P a g e
The expression joins two fields: custName and CustSurname
All the field should be added inside the square brackets when writing expression in MS access.

Using built in Text functions.

You can use built in functions when writing an


expression. To see list of text function:
1. Go to Expression Builder window again.
2. Under Expression Elements, expand Functions and
click Built-In Functions.
3. Under Expression Categories, select Text.
4. All Text Functions will be listed under Expression
Values.

Suppose we want to use a function to write the


initial, followed by (.), followed by space followed by surname of the customer.

Let us create a field called Initial_Surname.

Add a new field to the Customer table and call it Initial_Surname. The field should have Field
Type as Calculated.

1. Go to Expression Builder. To get the initial, we will use the Left function.
2. Type the following expression:

Left([custName]) & “ . ” & [CustSurname]

3. Click OK.

Class Exercise: Calculated Field

Go to veterinarian table and create a new calculated field called vetInfo. vetInfo field should
displays surname of veterinarian, followed by (,) followed by initial and (.)
For example:
Vet_name: Johnson
Vet_surname: Hill
vetInfo: Hill, J.

Numeric Fields

Calculated field is added using numeric values from other fields or built-in functions.
Mathematical expressions are used to do the computation.

105 | P a g e
In the payment table, suppose Total_cost is calculated from adding prescription_cost and
consultation_cost.
Now, add a field called Total_cost to payment table, and make its Data Type to be calculated.

Add the expression [prescription_cost]+[consultation_cost] to the Expression Builder, then


click OK.

The Result Type of the field should be currency.

Date fields

You can also use the addition and


subtraction operators with date
fields.

Add year_of_completion field as


calculated field. Use function
Year to return year of completion
for the field.

Using addition, you can add an


ordinary number to a date field.
This number moves the date
forward by that many days.

Text and Numeric Value

Strings and numeric vales can also be combined. Add another field to payment called price.
The expression for the field should be as below:

Price: "The price is: " & [Price]

Save the database and close.

106 | P a g e
WEEK 12: RELATIONSHIPS AND FORMS
OBJECTIVES

• Create Relationships
• Creating Forms

RELATIONSHIPS

One of the major advantages of databases like Microsoft Access is its ability to
maintain relationships between different data tables. The power of a database makes it
possible to correlate data in many ways and ensure the consistency (or referential
integrity) of this data from table to table.

CREATING RELATIONSHIPS BETWEEN TABLES

To prevent the duplication of information in a database by repeating fields in more than


one table, table relationships can be established to link fields of tables together. Follow the
steps below to set up a relational database:

1. Click on Database Tools tab


2. Click the Relationship button under
Relationships group.
3. From the Show Table window (Click the
Show Table button on the Relationship
group toolbar to make it appear),
4. Double click on the names of the tables you would like to
include in the relationships. When you have finished adding
tables click Close.
5. To link fields in two different tables, click and drag a field from
one table to the corresponding field on the other table and
release the mouse button. Let us create relationship between
Customer table and Orders table:

6. Drag CustID from customer and drop it on top of custNum on


orders.

107 | P a g e
The Relationships tab allows you to establish the relationship by clicking and dragging a
field over a field on another table. By dragging the Customer.CustId field over
Order.custNum, a relationship is established between the two tables, with
Customer.CustId as the primary key and Orders.CustNum as the foreign key.

The Edit Relationships window will appear. The Relationship Type is also shown.

7. From this window, you can select different fields


if necessary. In our case, it is not necessary as
appropriate field are already selected.
8. Select an option from Enforce Referential
Integrity if necessary. These options give MS
Access permission to automatically make changes
to referential tables if key records in one of the
tables are deleted. Check the Enforce Referential
Integrity box to ensure that the relationships are
valid, and that the data is not accidentally deleted
when data is added, edited, or deleted.

9. Click Create to create the link. A line now connects the two fields in the Relationship
window.

Class Exercise 1: Relationship

Create relationship between other tables so that your database is complete and should look
like the one below.

Now, let’s go to Datasheet View

The datasheet of a relational table will provide expand and collapse indicators to view sub-
datasheets containing matching information from the other table.

108 | P a g e
1. In the example below, the CUSTOMERS and ORDERS tables were related and the two
can be shown simultaneously using the expand feature.

2. To expand or collapse all sub-datasheets at once, select Format | Subdatasheet |


Expand All or Collapse All from the toolbar.

FORMS

Forms in Access are like display cases in stores that make it easier to view or get the items
that you want. Since forms are objects through which you or other users can add, edit, or
display the data stored in your database, the design of your form is an important aspect.
There's a lot you can do design-wise with forms in Microsoft Access. You can create two basic
types of forms −

• Bound forms
• Unbound forms

Bound Forms
Let us now understand what Bound Forms are −

• Bound forms are connected to some underlying data source such as a table, query, or
SQL statement.
• Bound forms are what people typically think of when they think of the purpose of a
form.
• Forms are to be filled out or used to enter or edit data in a database.
• Examples of bound forms will typically be what users use to enter, view or edit data in
a database.

109 | P a g e
Unbound Forms

• These forms are not connected to an underlying record or data source.


• Unbound forms could be dialog boxes, switch boards, or navigation forms.
• In other words, unbound forms are typically used to navigate or interact with the
database at large, as opposed to the data itself.

Types of Bound Forms


There are many types of bound forms you can create in Access. Let us understand the types:
Single Item Form
This is the most popular one and this is where the records are displayed — one record at a
time.
Multiple Item Form
This displays multiple records at a time from that bound data source.
Split Form
The form is divided into halves, either vertically or horizontally. One half displays a single
item or record, and the other half displays a list or provides a datasheet view of multiple
records from the underlying data source.

CREATING FORMS

There are a few methods you can use to create forms in Access.

Open your Database if it is not already open, then go to the Create tab.
In the Forms group, in the upper right-hand corner you will see the Form Wizard button.

1. Click on that button to launch the Form Wizard.

110 | P a g e
2. On this first screen in the wizard, you can select fields that you want to display on
your form, and you can choose from
fields from more than one table or a
query.
3. Let us assume we want to simply have a
quick form that we are going to use for
data entry for our customer information.
4. From Tables/Queries drop-down list,
select Customer table. Click on the
double arrow to move all the fields at
once.
5. Click Next.

The screen in the Form Wizard will ask for the


layout that we would like for our form. We
have columnar, tabular, datasheet and
justified layouts. We will choose the columnar
layout here and then click Next.

In the screen, we need to give a title for our


form. Let us call it frmcustomer.
Once you have given your form a title, you can
open the form to see what that form looks like,
or you can begin entering information into your
table. Or you can choose the option to modify
the form's design. Let us choose the first option to open the form to view or enter
information and click Finish.

This is a single item form, meaning one record is


displayed at a time and further down you can see
the navigation buttons, which is telling us that
this is displaying the record 1 of 9. If you click on
that button then, it will move to the next record.

If you want to jump to the very last record in that


form or that table, you can use the button right
beside that right arrow, the arrow with a line
after it, that's the last record button. If you want to add new employee information, go to the
end of this records and then after 4 records you will see a blank form where you can begin
entering out the new employee's information.

111 | P a g e
Let us now close this form and go to the
Create tab. Now we will create a slightly
more complicated form using Wizard.
Click the Form Wizard and this time, we
will choose fields from a couple of
different tables.
In this Form Wizard,
choose customer for Tables/Queries,
and select a few Available Fields such as
custname and Surname. These fields will
now move to Selected Fields.
Now select Order for Tables/Queries and send over the OrderNum and Date.

Click Next.
Here, we want to retrieve data from a couple
of different objects. We can also choose from
options on how we want to arrange our form.
If we want to create a flat form, we can choose
to arrange by order, which will create that
single form, with all the fields laid out in flat
view as shown above.
However, if we want to create a hierarchical
form based on that one-to-many relationship,
we can choose to arrange our data by
customer.
In the above window, we have the option to
include a subform for orders, or we can make that a linked form. This linked form is where
customer will have a button that will launch that second form filtered to the project that we
have selected in that underlying customer form.
Let us now select the Form with subform(s), and then click Next.

112 | P a g e
In the following screen, you can choose a layout for your subform. The Datasheet View gets
selected by default. The Datasheet View is similar to Table View. Now, click Next.
In the following screen, you need to provide a name for your forms. Enter the name you want
(e.g frmcustom_order) and click Finish.

Access will give you a preview of what your


form looks like. On top, you have the
controls on your main form, which is from
our customer table. As you go down, you
will see a subform. It's like a form within a
form.

Multiple Items Form.

1. Click Create tab


2. Click on the More Forms drop-down menu.
3. From the menu, you can create
a Multiple Items form,
a Datasheet form, a Split form,
or a Modal Dialog form. These
are typically bound forms; select
the object that you would like to
be bound to that form. This does
not apply to the Modal Dialog
forms.

113 | P a g e
To create this type of form, you will
need to select the object in
navigation pane first. Let us
select Product/Item here.

Proceed by clicking on More


Forms and Multiple Items.

The above steps will further create a


Multiple Items form, listing out all the
items/products.

Creating Split Form


This type of form is divided in equal
halves, either vertically or horizontally.
One half displays a single item or
record, and the other half displays a list
or a datasheet view of multiple records
from the underlying data source.
Let us now select order Details in the
navigation pane and then
on Create tab. Select Split Form option
from More Forms menu and you will
see the following form in which the
form is divided vertically.

Creating a Form in Design View

To create a form from scratch without


the wizard, follow these steps:

1. From the Create tab, click on the Form Design button under Forms group.
2. In the Tools group under Form Design Tools, click on the Existing Fields button
3. On the Field List pane on the right, click on Show All tables
4. Choose the table or query the form will be associated with from the drop-down menu.
5. Add controls to the form by clicking and dragging the field names from the Field List
floating window. Access creates a text box for the value and label for the field name when
this action is accomplished.

114 | P a g e
Adding Records Using a Form

Input data into the table by filling out the fields of the form. Press the Tab key to move from
field to field and create a new record by clicking the Tab key after the last field of the last
record. A new record can also be created at any time by clicking the New Record button
at the bottom of the form window. Records are automatically saved as they are entered so
no additional manual saving needs to be done.

Editing Forms

The following points may be helpful when modifying forms in


Design View:

1. Grid Lines – By default, a series of lines and dots underlay


the form in Design View so form elements can be easily
aligned. To toggle this feature on and right click on the form
and choose Grid from the menu that appears.

2. Resizing Objects – Form objects can be resized by clicking


and dragging the handles on the edges and corners of the
element with the mouse.

115 | P a g e
3. Change form object type – To easily change the type of form object without having to
create a new one, right click on the object with the mouse and select Change To and select
an available object type from the list.
4. Label/Object alignment – Each form object and
its corresponding label are bounded and will
move together when either one is moved with
the mouse. However, to change the position of
the object and label in relation to each other (to
move the label closer to a text box, for example),
click and drag the large handle at the top left
corner of the object or label.
5. Tab order – Alter the tab order of the objects on
the form by selecting Tools | Tab Order from the
ribbon (or right click on the form and choose Tab
Order from the subsequent menu). Click the gray
box before the row you would like to change in the tab order, drag it to a new location,
and release the mouse button.
6. Form Appearance – Change the background colour of the form by right clicking on the
form and choosing Fill/Back Colour from the menu that appears and then clicking one of
the colour swatches on the palette. Change the colour of individual form objects by right
clicking on one and selecting a colour from the Font/Fore Colour palette on the menu that
appears. Other properties like the size, position, font effect, alignment, border around
each object, special effect, etc can also be modified the same way.
7. Page Header and Footer – Headers and footers added to a form will only appear when it
is printed. Access these sections by right clicking on the form and choosing the appropriate
section from the menu that follows. A date and time can be added from Design |
Header/Footer|Date and Time.

116 | P a g e
WEEK 13: QUERIES AND REPORTS

OBJECTIVES

• Creating Simple Queries


• Creating Interactive Reports

QUERIES

Queries select records from one or more tables in a database so they can be viewed, analysed,
and sorted on a common datasheet. The resulting collection of records, called a dynaset
(short for dynamic subset), is saved as a database object and can therefore be easily used in
the future. The query will be updated whenever the original tables are updated.

Query Wildcards and Expression Operators


Wildcard/Operator Explanation
? Street The question mark is a wildcard that takes the place of a single
letter.
43th * The asterisk is the wildcard that represents a number of
characters
< 100 Value less than 100
>= 1 Value greater than or equal to 1
<> ”FL” Not equal to (all states besides Florida)
Between 1 and 10 Numbers between 1 and 10
Is Null Finds records with no value or all records that have a value
Is Not Null
Like “a*” All words beginning with “a”
> 0 and <= 10 All numbers greater than 0 and less than 10
“Bob” or “Jane” Values are Bob or Jane

TYPES OF QUERIES COVERED:

• Select
• Update
• Delete

Select Queries
Extract data from tables based on specified values, find duplicate queries that display records
with duplicate values for one or more of the specified fields, and find unmatched queries
display records from one table that do not have corresponding values in a second table.

117 | P a g e
Creating Select Query.

Let us create a query that gets data from one table with no criteria. Let's say our Food girls
company is having a special event, and want to invite all their customers. This means we need
to see a list of all customers in the database. A query must be created to display the
information as required. We are going to display customer’s id, surname, and name from
customer’s table.

To create a simple one-table query:

1. Open the Food girls database.


2. Select the Create tab on the Ribbon, and locate the Queries group.
3. Click the Query Design command.

4. Access will switch to Query Design


view. In the Show Table dialog box
that appears, select the table you
want to run a query on. We are
running a query to display all
customer, so we'll select
the Customers table.
5. Click Add Selected Tables, then
click Close.
6. The selected table will appear as a
small window in the Object
Relationship pane. In the table window, double-click the field names you want to
include in your query. They will be
added to the design grid in the bottom
part of the screen. In our example, we
want to display custID, name and
surname fields.
7. Run the query by clicking the Run
command on the Design tab.
8. The query results will be displayed in
the query's Datasheet view, which
looks like a table.

118 | P a g e
9. If you want, save your query by clicking
the Save command in the Quick Access
Toolbar. When prompted to name it, type
the desired name, then click OK.

Suppose you want column titles to be as below:

1. Go back to design view and edit the titles as below:

2. Run the query again.

Now you know how to create the simplest type of query with only one table.

One Table Query with Criteria

Suppose we want to display customer ids,names and surname of all customers who were
born before year 2000.

In this case our criteria is > 2000.

119 | P a g e
Add the query using customer’s
table and add all appropriate fields.

Note: DOB field is not checked under


Show as it does not have to be
displayed. However, it is used as a
criteria.

Under Criteria, type expression


Year([DOB])>2000.

Run the query. You can save your query with


any desired name.

Class Exercise 1: Query


1. Display all customers whose
surname starts with ”M”.
2. Display all customers who are older
than 20 years.

QUERY THAT USES MULTIPLE TABLES.

Suppose we want to display all orders placed by Moakofhi. The data to be displayed include
name of the customer who placed an order, order number and all items ordered. In this case,
name of the customer will come from the customer’s table, order number from orders table
and product name from product’s table.

Let us add the tables.

Run the query to see the results.

120 | P a g e
Save the query.

Now, let us add the criteria to


the query. Let suppose we want
to display all orders created by
Iris. We are going to modify the
above query to add the criteria.
The criteria is Iris under field
custName.

Results after running the query.

Select Queries – Totals/Aggregating


You can sum a column of numbers in a query by using a type of function called an aggregate
function. Aggregate functions perform a calculation on a column of data and return a single
value. Access provides a variety of aggregate functions, including Sum, Count, Avg (for
computing averages), Min and Max. You sum data by adding the Sum function to your query,
you count data by using the Count function, and so on.

In addition, Access provides several ways to add Sum and other aggregate functions to a
query. You can:

▪ Open your query in Datasheet view and add a Total row. The Total Row, a feature in
Access, allows you to use an aggregate function in one or more columns of a query
result set without having to change the design of your query.

Class Exercise 2: Query Aggregate

Do the following to add Total row to Orders placed by Iris query.

1. Make sure that your query is open in Datasheet view.


2. On the Home tab, in the Records group, click Totals.

121 | P a g e
A new Total row appears in your datasheet.

1. In the Total row, click the cell in the field that you want to sum, and then
select Sum from the list.

Hide a Total row

On the Home tab, in the Records group, Click Totals.

1. Create a totals query. A totals query calculates subtotals across groups of records; a Total
row calculates grand totals for one or more columns (fields) of data. For example, if you
want to subtotal all orders by each customer or by year, you use a totals query to group
your records by the desired category and
you then sum of all sold items.
2. Let us create a query that computes total
number of orders made by each customer.
3. On the Create tab, in the Other group,
click Query Design.
4. In the Show Table dialog box, add table
that you want to use in your query. Let us
add all the tables and then click Close.

1. Add all the fields (Surname and orderNum)


and then Click the total button.
2. The Total row appears in the design grid
and Group By appears. Under orderNum
change Group By to Count.

122 | P a g e
3. Click Run to run the query and display
the results in Datasheet view.
4. Save the query.

Parameter Queries

The criteria is dynamic – every time a parameterized query is run, the user is prompted to
enter the criteria value they want to use.

Creating Parameter Query

Suppose we want to create a query that search a customer by surname, then displace
information about the searched customer.

1. Click on create, then Query Design


2. Add customer table, to the query window.
3. Add all the fields to be displayed. Let us add all the
fields from customer table.
4. For the Criteria, under the surname create square
brackets and add “Please enter the surname” as
below:

Note: The surname checkbox under Show is not check.


This is because we know that the query is going to display
surname entered, so no need to have the column that
repeats the surname.

5. Run the query. The window below is displayed


asking the user to enter the surname to be
searched. Enter any surname on the table and click
OK
6. Results if surname Leteane is entered.

123 | P a g e
Update Queries

An Update Query is an action query (SQL statement) that changes a set of records according
to criteria (search conditions) you specify. It's a very powerful feature and a fundamental part
of relational databases since you can modify a huge number of records at one time.
Understanding and using Update Queries improves the performance of your applications
(versus doing the same changes manually or in code), and makes them easier to maintain.

Creating Update Query

1. Click Create, then query Design.


2. Add the table with data to be updated.
3. Then Click update on the
Query Type Group.
4. The query window will now
look like the one below.

Note: Notice the new row called Update To:

5. Let us update date of birth for one of the records. In this example, we will change the date
of birth for customer number 2007 from 2013/04/28 to 1983/03/03.

6. Add the following changes to the query:

124 | P a g e
7. Run the query. The message will be displayed:
8. Click Yes to update the record. Now, go to
datasheet view of the table and you will see that
the record is updated.

9. Save the query.

Delete Query

When to either quickly delete a lot of data or delete a set of data on a regular basis in
an Access desktop database, a delete or an update query might be useful because the
queries make it possible to specify criteria to quickly find and delete the data.

Creating Delete Query

1. Click Create, then query Design.


2. Add the table with data to be
deleted.
3. Then Click Delete on the Query Type
Group. Notice the new row called
Delete:
4. Enter any time from which you want to delete a record.
5. Specify the criteria and run the query to delete the record.

REPORTS

Reports will organise and group information in a table or query and provide a way to print
that data in a database.

Creating a Report Using Wizard

To create a report using the assistance of the wizard, follow these steps:

1. Click the Report Wizard button from the Reports group under Create tab

125 | P a g e
2. Select the table or query whose datasheet the report will be associated with from the
Tables/Queries drop-down menu.

3. Select the fields that will be included on the report by highlighting each on the Available
Fields window and clicking the single right button > to move the field to the Selected
Fields window.

4. To move all the fields to the Selected Fields window at once, click the double right arrow
button >>. If you make a mistake and would like to remove a field or all the fields from
the Selected Fields window, click the left arrow < or left double arrow << buttons
respectively. After the proper fields have been selected, click the Next > button to move
on to the next screen.

5. Select fields from the list that the records should be grouped by and click the right arrow
button > to add those fields to the diagram. Use the Priority buttons to change the order
of the grouped fields if more than one field
is selected. Click Next > to continue.

6. If the records should be sorted, identify a


sort order here. Select the first field that
records should be sorted by and click the
Ascending button to choose from ascending
or descending order. Click Next > to
continue.

126 | P a g e
7. Select a layout and page orientation for the report and
click Next >.

8. On the final screen, name the report and select to open it in either Print Preview or Design
View mode. Click the Finish button to create the report.

Creating a Report in Design View

To create a report from scratch follow these steps:

1. From the Create tab, click on the Report Design button under Reports group.
2. You will be presented with a blank grid that looks like the Design View for forms. Design
the report in much the same way you would create a form. For example, use the handles
on the elements to resize fields, move them to different locations, and modify the look of
the report by using options on the formatting toolbar. Click the Print View button at the
top left corner of the screen to preview the report.

Printing Reports

Right click on the report and choose Print Preview from the menu that appears. Use the Print
Preview tab on the ribbon to modify the page margins, size, orientation, and column setup.
After all changes have been made, print the report by selecting File | Print from the ribbon.

127 | P a g e
FACULTY: SCIENCES

DEPARTMENT: Biometry and Mathematics

COURSE CODE AND TITLE: ICT122 Computer Skills Fundamentals II

COURSE FACILITATORS:

Mrs D. M. Monchusi Office: Block 108B; Room 8


Email: [email protected]

Mrs T. V. Phiri Office: Block 108B; Room 2


Email: [email protected]

Mrs I. Mosipuri Office: Block 302; Room 10


Email: [email protected]

CREDITS 2
TYPE General Education Course
SEMESTER 2
PRE-REQUISITES None
CO-REQUISITES None

COURSE SYNOPSIS

This course is designed to help learners develop presentation skills; Introduction to


spreadsheet concepts and principles; Use of basic spreadsheet applications package facilities;
Introduction to database concepts and principles.

128 | P a g e
RATIONALE

This course offers a further introduction to the computer system environment and problem-
solving with the help of the computer. The emphasis is on practical hands-on experience. The
course helps students with understanding presentation skills. It will also focus on equipping
student with basic spreadsheet and database skills. It will introduce further computing skills.
The course will further equip students with basic skills require for academic work.

AIMS AND OBJECTIVES.

Upon successful completion of this course, students will be able to:


1. Knowledge and skills on the use of presentation application
1.1. Demonstrate knowledge and skills on developing presentations using Microsoft PowerPoint
(creating slides, making changes to a presentation, printing slides).

2. Demonstrate knowledge and skills in using spreadsheet application.


2.1. Recognize, discuss, and investigate how spreadsheets are used in a variety of settings (e.g
schools, government, business, industry, transportation, communications)
2.2. Demonstrate knowledge and skills on using spreadsheet to solve simple problems.
2.3. Demonstrate knowledge and skills on using advanced spreadsheet functions to solve
problems.
2.4. Select and use spreadsheet formulas and functions to solve problems in content area.
2.5. Use spreadsheet to analyse and interpret information, test simple “what-if “statements and
make decisions in content areas.

3. Demonstrate knowledge and skills in using database application.


3.1. List different components of Microsoft Access user interface.
3.2. Demonstrate knowledge and skills in identifying different objects of a Microsoft Access
database.
3.3. Demonstrate knowledge and skills in understanding the different views of Microsoft Access
database, object interactions, data types, field properties, and representation of primary keys
and foreign keys.
3.4. Demonstrate knowledge and skills in distinguishing between table and field properties.
3.5. Demonstrate knowledge and skills on using tables and relationships in a database.
3.6. Apply database skills to solve problems in content areas.

129 | P a g e
COURSE OUTLINE

WEEK LECTURE TOPIC SUMMARY LAB. SESSION


Overview of the course.
House Keeping.
Lab group allocation.
Lecture 1: Understanding concepts of
Week 1 Basic PowerPoint operations;
Introduction to multimedia information
Formatting; Graphics and
Presentation Basics. presentation; Best practice in
Charts.
creating presentations
Understanding different
audience types
(professionals, students etc.);
Week 2 Lecture 2: Creating Presentation for Creating a spreadsheet,
Presentation Basics Different Audiences and best workbooks, and worksheets.
practices in giving
presentations.
Understanding basic
Creating a spreadsheet,
Lecture 3: spreadsheet application
workbooks, and worksheets.
Introduction to basic concepts and principles;
Week 3
Spreadsheet applications Basic spreadsheet terms and
Organizing and Formatting
concepts and principles. definitions.
Workbooks.
Lecture 4:
How to work with Formulas Formatting Workbooks.
Using Formula to create
and Functions operators and
Week 4 and interpret data.
its usage. Cell Referencing and
Cell references. Formulas.
Cell Refencing.
What are functions: simple
Lecture 5:
syntax of commonly used
Problem-Solving Concepts
functions. Using Functions and Formulas
and Principles in MS Excel
Week 5 to create and interpret data.
2019
Understanding and using
different types of charts and Lab Exercise 1
Charts and Graphs.
graphs to analyse data.

Lecture 6: Advanced Using advanced functions and


functions (Joining sheets,
Complex functions and formulas to create and
Week 6 Mathematical, Statistical,
formulas. interpret data.
Lookup, Financial,
Database). Quiz 1 (Online – Eduhub)

130 | P a g e
WEEK 7 : MID-SEMESTER BREAK
Lecture 7: Advanced
Creating a database using MS
functions (Joining sheets,
Complex Functions and Access.
Week 8 Mathematical, Statistical,
Formulas. Creating tables; Entering and
Lookup, Financial,
Modifying records on a table.
Database).
Basic Concepts; Definition of
Lecture 8: Introduction to database, Database
Week 9 Practical Test 1
Database Concepts. Management System; Types
of databases.
Public Holidays 1st and 2nd
May
Week 10
Lab opened on Wed – Fri for
practicing.

Lecture 9: Relational Relational Models; Relational Relationships; Creating


Week 11 Forms.
Database Concepts. Database illustrations.
Lab Exercise 2

Creating Queries and Reports.


Lecture 10: MS Access Data Manipulation
Week 12 Different types of queries;
2019: Queries and Reports Quiz 2 (Online on Eduhub).
Reports creation

Lecture 11: Database Entity Relationship Models


Week 13 (ERM) conventions; Relating Theory Test
Modelling.
multiple tables.
Lecture 13: Problem
Solving Using MS
Week 14 Practical Test 2
Excel/Access and
Revision.

Week 15 NO ASSESSSMENTS IN THIS WEEK

MODE OF ASSESSMENT

Continuous Assessment: This will comprise one theory test, two practical tests, two quizzes
and two laboratory exercises. Continuous Assessment will contribute 50 % of the total score,
with the other 50 % coming from the Final Examination, to be written at the end of the
semester. Thus, the ratio between continuous assessment and the final examination will be
1:1.

131 | P a g e
CONTINUOUS ASSESSMENT BREAK DOWN (50%)

Theory Test: 25 % Lab Exercise 1: 5%


Quiz 1: 7.5 % Lab Exercise 2: 5%
Quiz 2: 7.5 % Practical Test 1: 25 %
Practical Test 2: 25 %

SCHEDULE OF CONTINUOUS ASSESSMENTS

SEMESTER
ASSESSMENT TYPE DATES
WEEK
MON 27TH MARCH 2023 – FRI 31ST MARCH
5 LAB EXERCISE 1
2023
WED 5TH APRIL 2023
6 QUIZ 1 (ONLINE) EDUHUB
(OPENS: 09:00AM – CLOSES: 21:00 PM)
9 PRACTICAL TEST 1 24TH APRIL 2023 – 28TH APRIL 2023

11 LAB EXERCISE 2 8TH MAY 2023 – 12TH MAY 2023


WED 17TH MAY 2023
12 QUIZ 2 (ONLINE) EDUHUB
(OPENS: 09:00AM, CLOSES: 21:00 PM)
13 THEORY TEST THURSDAY 25TH JUNE 2023
14 PRACTICAL TEST 2 MON 29TH MAY 2023 – FRI 2ND JUNE 2023

RECOMMENDED TEXTBOOK

Parsons, J. J., & Oja, D. (2014). Practical Computer Literacy (with CD-ROM) (New Perspectives)
(4th ed.). Boston: Thomson Course Technology.

READING (AND OTHER RESOURCES) LIST


1. O’Leary, T. J., O’Leary, L. I., & O’Leary, D. (2021). Computing Essentials 2021: Making IT
work for you, Introductory (25th ed.). New York: McGraw-Hill International.
2. Wempen, F. (2015). Computing Fundamentals: Introduction to Computers. Indianapolis,
Indiana: John Wiley & Sons, Inc.
3. Morrison, C., Wells, D., & Ruffolo, L. (2015). Computer Literacy BASICS: A Comprehensive
Guide to IC3 (5th ed.). Stamford: Cengage Learning.
4. Arora, A. (2015). Computer Fundamentals and Applications. New Delhi: Vikas Publishing
House Pvt Ltd.
5. Easttom, W. (2020). Computer Security Fundamentals (4th ed.). Indianapolis, Indiana:
Pearson IT Certification.
6. Lectures Notes available online (Eduhub).

132 | P a g e
WARNING:

• PLEASE NOTE: THERE WILL BE NO MAKE-UP FOR LAB EXERCISES AND TESTS PROVIDED.

• MAKE SURE YOU WRITE ALL YOUR LAB ASSESSMENTS IN YOUR ALLOCATED GROUP SLOT/DAY.

• THE USE OF MOBILE PHONES DURING PRACTICAL TESTS, QUIZZES, LABORATORY EXERCISES,
THEORY TEST AND FINAL EXAMINATION IS PROHIBITED.

• IF YOU MISS ANY OF THE CONTINUOUS ASSESSMENTS, YOU HAVE FIVE (5) WORKING DAYS TO
NOTIFY ANY OF ICT122 COORDINATORS (WITH A VALID REASON(S) TO SUPPORT YOUR
ABSENTEEISM), ELSE YOU WILL BE GIVEN A ZERO (0) MARK.

• CHEATING DURING ANY OF THE CONTINOUS ASSESSMENTS AND FINAL EXAMINATIONS IS A


SERIOUS OFFENCE WHICH MAY RESULT IN LOSS OF MARKS OR CREDITS, SUSPENSION OR
EXPULSION. PLEASE, YOU ARE ADVISED TO REFRAIN FROM IT (ACADEMIC REGULATIONS 4.470
& 4.472)

• FINALLY, ALWAYS WASH HANDS WITH CLEAN WATER AND SOAP, SANITISE HANDS, AND STAY
SAFE FROM COVID-19.

• MAKE APPOINTMENT WITH ANY OF THE COURSE FACILLTATOR ON ANY TOPIC(S) YOU ARE
HAVING A CHALLENGE TO UNDERSTAND.

133 | P a g e
ICT122 LECTURES AND PRACTICAL SESSIONS TIMETABLE

DAYS OF THE WEEK


TIME (HRS) MONDAY TUESDAY WEDNESDAY THURSDAY FRIDAY
ICT122 C1[1]
07:00 – 08:00 VENUE: A1 (311/002)
PHIRI ICT122 P1[8]
VENUE: 305/001
0800 – 09:00 PHIRI
ICT122 P1[4] ICT122 P1[5] ICT122 P1[9]
09:00 – 10:00 VENUE: 305/001 VENUE: 305/001 VENUE: 305/001
MOSIPURI MOSIPURI MONCHUSI
1000 – 1100
ICT122 C2 [2]
1100 – 1200 VENUE: B1 (311/002)
PHIRI
1200 – 13:00
13:00 – 14:00

ICT122 P1[2] ICT122 P1[3] ICT122 P1[7] ICT122 P1[6] ICT122 P1[1]
1400 – 1655 VENUE: 305/001 VENUE: 305/001 VENUE: 305/001 VENUE: 305/001 VENUE: 305/001
PHIRI PHIRI MOSIPURI MONCHUSI MONCHUSI

134 | P a g e

You might also like