Microsoft Access 2013 ®® Tutorial 10 Automating Tasks with Macros.

Slides:



Advertisements
Similar presentations
Objectives Create an action query to create a table
Advertisements

1 Microsoft Access 2002 Tutorial 9 – Automating Tasks With Macros.
With Microsoft Access 2010© 2011 Pearson Education, Inc. Publishing as Prentice Hall1 PowerPoint Presentation to Accompany GO! with Microsoft ® Access.
Developing an Excel Application
Access Tutorial 3 Maintaining and Querying a Database
Automating Tasks With Macros
Exploring Office Grauer and Barber 1 Creating More Powerful Applications: Introduction to VBA(Wk9)
Access Tutorial 1 Creating a Database
Automating Tasks With Macros. 2 Design a switchboard and dialog box for a graphical user interface Database developers interact directly with Access.
Tutorial 6 Using Form Tools and Creating Custom Forms
XP New Perspectives on Microsoft Office Access 2003, Second Edition- Tutorial 1 1 Microsoft Access 2003 Tutorial 1 – Introduction To Microsoft Access 2003.
1 Chapter 1 Tour of Access. 1 Chapter Objectives Start and exit Microsoft Access Open and run an Access application Identify the major elements of the.
Access Tutorial 4 Creating Forms and Reports
Access Tutorial 3 Maintaining and Querying a Database
Access Lesson 4 Creating and Modifying Forms
Automating Tasks with Macros. Macro Essentials  A macro is a list of actions that happen when you run the macro.  Creating a Macro: − Choose Create.
Access Tutorial 10 Automating Tasks with Macros
Chapter 9 Macros, Navigation Forms, PivotTables, and PivotCharts
Tutorial 1 Creating a Database. Objectives Learn basic database concepts and terms Learn basic database concepts and terms Explore the Microsoft Access.
WORKING WITH MACROS CHAPTER 10 WORKING WITH MACROS.
Maintaining and Querying a Database Microsoft Access 2010.
Pasewark & Pasewark Microsoft Office 2003: Introductory 1 INTRODUCTORY MICROSOFT ACCESS Lesson 1 – Access Basics.
Unit J: Creating a Database Microsoft Office Illustrated Fundamentals.
Microsoft Office 2013 ®® Access Tutorial 4 Creating Forms and Reports.
® Microsoft Access 2010 Tutorial 7 Creating Custom Reports.
Automating Tasks with Visual Basic. Introduction  When can’t find a readymade macro action that does the job you want, you can use Visual Basic code.
Tutorial 11 Using and Writing Visual Basic for Applications Code
INSERT BOOK COVER 1Copyright © 2011 Pearson Education, Inc. Publishing as Prentice Hall. Exploring Microsoft Office Access 2010 by Robert Grauer, Keith.
Chapter 6 Advanced Report Techniques
Automating Database Processing Chapter 6. Chapter Introduction Design and implement user-friendly menu – Called navigation form Macros – Automate repetitive.
® Microsoft Office 2010 Access Tutorial 3 Maintaining and Querying a Database.
Microsoft Office 2007 Access Chapter 6 Using Macros, Switchboards, PivotTables, and PivotCharts.
FIRST COURSE Access Tutorial 4 Creating Forms and Reports.
Automating Database Processing
Tutorial 4 Creating Forms and Reports
® Microsoft Office 2010 Access Tutorial 3 Maintaining and Querying a Database.
Key Applications Module Lesson 21 — Access Essentials
XP New Perspectives on Microsoft Access 2002 Tutorial 1 1 Microsoft Access 2002 Tutorial 1 – Introduction To Microsoft Access 2002.
® Microsoft Access 2010 Tutorial 9 Using Action Queries and Advanced Table Relationships.
Office 2003 Post-Advanced Concepts and Techniques M i c r o s o f t Access Project 7 Advanced Report and Form Techniques.
® Microsoft Office 2013 Access Creating a Database.
Tutorial 9 Using Action Queries and Advanced Table Relationships.
® Microsoft Access 2010 Tutorial 12 Managing and Securing a Database.
COMPREHENSIVE Access Tutorial 3 Maintaining and Querying a Database.
There are seven main components of a database in Access 2000: Tables. Use tables to store database information. Forms Use forms to enter or edit the information.
® Microsoft Office 2013 Access Maintaining and Querying a Database.
® Microsoft Access 2010 Tutorial 10 Automating Tasks with Macros.
Access Lesson 11 Creating and Running Macros Microsoft Office 2010 Advanced Cable / Morrison 1.
1 MIS309 Database Systems Introduction to Microsoft Access.
Microsoft Access 2013 ®® Tutorial 12 Managing and Securing a Database.
XP New Perspectives on Microsoft Office Access 2003 Tutorial 10 1 Microsoft Office Access 2003 Tutorial 10 – Automating Tasks With Macros.
Chapter Fourteen Access Databases and SQL Programming with Microsoft Visual Basic th Edition.
XP New Perspectives on Microsoft Office FrontPage 2003 Tutorial 7 1 Microsoft Office FrontPage 2003 Tutorial 8 – Integrating a Database with a FrontPage.
INTRODUCTION TO ACCESS. OBJECTIVES  Define the terms field, record, table, relational database, primary key, and foreign key  Create a blank database.
XP New Perspectives on Microsoft Office Access 2003, Second Edition- Tutorial 6 1 Microsoft Office Access 2003 Tutorial 6 – Creating Custom Forms.
Chapter Fourteen Access Databases and SQL Programming with Microsoft Visual Basic th Edition.
® Microsoft Office 2010 Access Tutorial 4 Creating Forms and Reports.
® Microsoft Access 2010 Tutorial 9 Using Action Queries and Advanced Table Relationships.
Programming with Microsoft Visual Basic 2012 Chapter 14: Access Databases and SQL.
COMPREHENSIVE Excel Tutorial 12 Expanding Excel with Visual Basic for Applications.
Microsoft Access 2013 ®® Case Study Creating a Database.
Access Tutorial 3 Maintaining and Querying a Database
Objectives Create an action query to create a table
Microsoft Excel 2003 Illustrated Complete
Access Tutorial 4 Creating Forms and Reports
Tutorial 4 Creating Forms and Reports
Case Study Creating a Database
Exploring Microsoft® Access® 2016 Series Editor Mary Anne Poatsy
Lesson 1 - Automating Tasks
Tutorial 10 Automating Tasks with Macros
Presentation transcript:

Microsoft Access 2013 ®® Tutorial 10 Automating Tasks with Macros

XP Objectives Session 10.1 – Run and add actions to macros – Single step a macro – Create a submacro – Add a command button to a form – Attach a macro to a command Button New Perspectives on Microsoft Access 20132

XP Objectives Session 10.2 – Create an unbound form – Add a list box to a form – Use a SQL statement to fill a list box with object names – Create multiple macros for a form – Create a navigation form New Perspectives on Microsoft Access 20133

XP Creating a User Interface Case - Chatham Community Health Services Creating a User Interface for the Health Database User would like to implement a user interface for the Health database. For less experienced users, he would like the interface will display specific forms and reports, and all the queries in the database, so that users can select objects they want to work with from the interface For more advanced users, a form that has some buttons that users can click to perform common tasks will be created New Perspectives on Microsoft Access 20134

XP Creating a User Interface (Cont.) New Perspectives on Microsoft Access 20135

XP New Perspectives on Microsoft Access Creating a User Interface (Cont.)

XP New Perspectives on Microsoft Access Introduction to Macros

XP New Perspectives on Microsoft Access Running a Macro

XP Running a Macro (Cont.) New Perspectives on Microsoft Access 20139

XP Adding Actions to a Macro New Perspectives on Microsoft Access Arguments – A piece of data that is required by an action – MessageBox Four arguments: The Message argument contains text that appears in the message box when it is displayed The Beep argument (Yes or No), specifies whether a beep will sound when the message box opens The Type argument determines which icon, if any, appears Choices are None, Critical Warning? Warning! and Information The Title argument contains the word(s) that will appear in the message box title

XP Adding Actions to a Macro (Cont.) New Perspectives on Microsoft Access

XP Adding Actions to a Macro (Cont.) New Perspectives on Microsoft Access

XP Adding Actions to a Macro (Cont.) New Perspectives on Microsoft Access

XP Single Stepping a Macro New Perspectives on Microsoft Access Single Step Mode – Executes a macro one action at a time, pausing between actions – called single stepping – Allows you to make sure you have placed actions in the right order and with the correct arguments – You can use single step mode to find the causes of problems and to determine corrections – The Single Step button on the DESIGN tab is a toggle you use to turn single step mode on and off Once you turn on single step mode, it stays on for all macros until you turn it off

XP Single Stepping a Macro (Cont.) New Perspectives on Microsoft Access

XP Using a Command Button with an Attached Macro New Perspectives on Microsoft Access

XP Using a Command Button with an Attached Macro (Cont.) New Perspectives on Microsoft Access Event – A state, condition, or occurrence detectable by Access Event Property – Specifies how an object responds when an event occurs Event Procedure – A group of statements using VBA code that Access executes together

XP Using a Command Button with an Attached Macro (Cont.) New Perspectives on Microsoft Access

XP Submacros New Perspectives on Microsoft Access A submacro is a complete macro with a Submacro header within a macro – Allows you to consolidate related macros and to manage large numbers of macros

XP Submacros (Cont.) New Perspectives on Microsoft Access

XP Submacros (Cont.) New Perspectives on Microsoft Access The Table Name argument specifies the name of a table that will be opened when the macro is run The View argument specifies the view in which the object opens. The Data Mode argument specifies the table’s data- entry options – Allowable settings for this argument are Add (users can add new records but can’t change or delete existing records), Edit (change and delete existing records and can add new records), and Read Only (only view records) – If you don’t select an argument value, Edit is the default setting

XP Adding a Submacro New Perspectives on Microsoft Access The SelectObject action selects a specified object so that you can run an action that applies to the Object The RunMenuCommand action selects and runs a command on the ribbon The PrintSelection argument, which prints the selected form record

XP Adding a Submacro (Cont.) New Perspectives on Microsoft Access

XP Adding a Command Button to a Form New Perspectives on Microsoft Access

XP Attaching a Submacro New Perspectives on Microsoft Access

XP Attaching a Submacro (Cont.) New Perspectives on Microsoft Access

XP Designing a User Interface New Perspectives on Microsoft Access

XP Creating the frmQueries Form New Perspectives on Microsoft Access

XP Adding a List Box to a Form New Perspectives on Microsoft Access

XP Adding a List Box to a Form (Cont.) New Perspectives on Microsoft Access

XP SQL (Structured Query Language) – A standard language used in querying, updating, and managing relational databases – Used mostly in a relational DBMS such as mySQL or Oracle Using SQL New Perspectives on Microsoft Access

XP Viewing a SQL Statement for a Query Using SQL (Cont.) New Perspectives on Microsoft Access

XP SELECT Statement – The basic form of a SQL SELECT statement includes four sections, known as clauses – Each clause starts with a different keyword: SELECT, FROM, WHERE, and ORDER BY – After the SELECT keyword, you list the fields you want to display – After FROM, you list the tables used in the query – After WHERE, you list the selection criteria – After ORDER BY, you list the sort fields Using SQL (Cont.) New Perspectives on Microsoft Access

XP Using SQL (Cont.) New Perspectives on Microsoft Access

XP Using a SQL Statement for a List Box – System tables are special tables maintained by Access that store information about the characteristics of a database and about the structure of the objects in the database – Although system tables do not appear in the Navigation Pane, you can retrieve information from system tables using SELECT statements – One of the system tables, the MSysObjects table, keeps track of the names, types, and other characteristics of every object in a database Using SQL (Cont.) New Perspectives on Microsoft Access

XP Using SQL (Cont.) New Perspectives on Microsoft Access

XP Using SQL (Cont.) New Perspectives on Microsoft Access

XP Adding a Command Button to a Form New Perspectives on Microsoft Access

XP Adding a Command Button to a Form (Cont.) New Perspectives on Microsoft Access

XP Adding a Command Button to a Form (Cont.) New Perspectives on Microsoft Access

XP Creating the Macros for the frmQueries Form New Perspectives on Microsoft Access – Load Event Occurs when Access opens a form or report

XP Creating the Macros for the frmQueries Form (Cont.) New Perspectives on Microsoft Access

XP Creating the Macros for the frmQueries Form (Cont.) New Perspectives on Microsoft Access

XP Testing the frmQueries Form New Perspectives on Microsoft Access After creating a custom form, you should test the form in Form view – For the frmQueries form, you need to double-click a query name in the list box to make sure the query datasheet opens – Also, you must scroll the list box, click a query name, and then click the Display command button to make sure the query datasheet opens, and also click the Preview command button to make sure the query opens in Print Preview

XP Creating a Navigation Form New Perspectives on Microsoft Access

XP Creating a Navigation Form (Cont.) New Perspectives on Microsoft Access

XP Creating a Navigation Form (Cont.) New Perspectives on Microsoft Access

XP Creating a Navigation Form (Cont.) New Perspectives on Microsoft Access