Hands-On-8 Advancing with VBA

Size: px
Start display at page:

Download "Hands-On-8 Advancing with VBA"

Transcription

1 Hands-On-8 Advancing with VBA Creating Event Procedures In this exercise you will create a message box that will display a welcome message to the user each time your database is opened. Before starting this exercise you should have completed Hands-on 5 and set the form frmmainmenu to be the start-up form when the database opens. Start Access and open your baccsamp.mdb database. Change the form to Design view. The entire form will automatically be selected by default. The event procedure you are going to create will be linked to the OnOpen property of the form. Later, when you are creating your own procedures, you may select a single control for which the event procedure is created. Click the Properties button on the toolbar. Microsoft Access displays the property sheet for the form, report, or control. Click the Event tab to display the Event Properties. Select the event that will trigger the event procedure - for this task you will use the On Open event property. Select [Event Procedure] from the list. Click the Build button to display the Module window. Type the event procedure code between the Sub line and the End Sub line. ho-080.doc 1 07/12/ :02

2 Click the Debug button on the top level menu and click Compile to compile the module and check for errors in the event procedure. Save changes to the module. When the form or report is open, each occurrence of the event will cause the event procedure to be called. Save the form. Close it and open it again to see your procedure working. Before the form opens you should see the message box on the screen. When you click the OK button the form will open. Functions In this exercise you will create a general function, called Confirm, that performs the same task for any action that needs confirmation. The function will return a different value depending upon the choice made by the user. Close any open objects to return to the database window. Select the Module tab and press New. The new module will automatically contain the declarations section which apply to the entire module, for example, the Option Compare Database statement. Add Option Explicit to enforce the explicit declaration of all variables in the module. NB: When you use this statement, you cannot use a variable which has not been declared. Module: Module 1 Option Compare database Option Explicit Select Insert, Procedure. Select type as function and enter the name as Confirm in the Name box. Press OK. ho-080.doc 2 07/12/ :02

3 Enter the code as shown below Module: Module 1 Public Function Confirm(strMessage As String) 'Display an important message to the user. MsgBox strmessage, vbokcancel End Function Compiling Code You need to compile all VBA code before you can use it so that Access can check that there are no errors. Click the Debug button on the top level menu and click Compile to compile the module and check for errors in the event procedure. Save the module as modutilities. Using the Function You are now going to try out the Utilities function by adding a button to a test form. Open a new form in Design View. Create a new button called cmdtestmessage. Enter the function and the question you want to use in the On Click Event property of the button - see below: Switch to form view and click the button. Your message should appear. Save the form as frmtestbuttons. ho-080.doc 3 07/12/ :02

4 Create a function that can be used to trigger an event You've already seen that using a general function can help to streamline your application's performance in many ways. For example, you may need to constantly update a set of records from different forms within your application. You could achieve this by creating a command button with an event procedure, but you would need to duplicate it many times. To cut down on repetitive code writing, you may decide to create a general function that can be used at any time. Open the modutilities Module from the database window. Create a function NewRec Enter the following Code into your new function. Public Function NewRec(strFormName As String) ' This function is used in the Click event of command buttons to open forms and create a new record. 'Using a function is often more efficient ' than repeating the same code in multiple event procedures. ' Open specified form. DoCmd.OpenForm strformname,,,, acformadd DoCmd.Maximize End Function Compile and Save the Module. Close it. Open the frmtest Buttons form. Create a new button labelled Add New Customer. Attach the function =NewRec("frmCustomers) to the OnClick field of the button. Save the form and test that the function works. (What do you expect it to do?) Linking a Sub Procedure to a command button In this exercise you will create an event sub procedure that goes through the tblcustomers table and counts the number of Wine club Members. Open the frmtestbuttons form. Create a command button called cmdcountcustomers. Label the button Customer Count. ho-080.doc 4 07/12/ :02

5 Create the following sub procedure attached to the On Click event of the command button. Private Sub CountCustomers_Click() Dim dbs As Database, rst As Recordset ' Return reference to current database. Set dbs = CurrentDb ' Open table-type Recordset object. Set rst = dbs.openrecordset("tblcustomers") MsgBox "No of Records = " & rst.recordcount rst.close Set dbs = Nothing End Sub Compile and test the procedure by switching to form view and clicking the button. (how can you check that the message box is displaying the correct count?) Create a personalised Welcome message In this exercise you will create an Input Box that will prompt the user for their name and then display a personalised message. On the form frmtest buttons, create a command button called cmdwelcome and give it the label Welcome. Create the following sub procedure attached to the On Click event of the command button. Test the button Private Sub cmdwelcome_click() Dim yourname As String ' store the value entered by the user in a variable yourname = InputBox("What is your Name?") ' display the value of the variable MsgBox "Welcome, " & yourname End Sub Input boxes can be used to get a value from the user and store it in a variable. Challenge (optional extra) This is an optional extra to help you to test your understanding of VBA. It does not contain step-by-step instructions as it is designed to make you think. Before attempting it, make sure the procedures and functions you have created so far are working correctly and that you understand them. Create a general purpose function to count the records in any table The CountMembers sub procedure can only count the records in tblmembers. It would be useful to create a general purpose function RecCount that would count the records in any table specified by the user. Where should such a function be stored? What argument needs to be passed to the function? ho-080.doc 5 07/12/ :02

6 Think about the NewRec function you created earlier. Once you have decided on the answers to the questions above, create the function. The code will be identical to the code for the CountMembers sub except that it will use a variable as the argument to the OpenRecordset method. ho-080.doc 6 07/12/ :02

d2vbaref.doc Page 1 of 22 05/11/02 14:21

d2vbaref.doc Page 1 of 22 05/11/02 14:21 Database Design 2 1. VBA or Macros?... 2 1.1 Advantages of VBA:... 2 1.2 When to use macros... 3 1.3 From here...... 3 2. A simple event procedure... 4 2.1 The code explained... 4 2.2 How does the error

More information

A Back-End Link Checker for Your Access Database

A Back-End Link Checker for Your Access Database A Back-End for Your Access Database Published: 30 September 2018 Author: Martin Green Screenshots: Access 2016, Windows 10 For Access Versions: 2007, 2010, 2013, 2016 Working with Split Databases When

More information

Simply Access Tips. Issue May 4 th, Welcome to the thirteenth edition of Simply Access Tips for 2007.

Simply Access Tips. Issue May 4 th, Welcome to the thirteenth edition of Simply Access Tips for 2007. Hi [FirstName], Simply Access Tips Issue 13 2007 May 4 th, 2007 Welcome to the thirteenth edition of Simply Access Tips for 2007. Housekeeping as usual is at the end of the Newsletter so, if you need to

More information

Simply Access Tips. Issue April 26 th, Welcome to the twelfth edition of Simply Access Tips for 2007.

Simply Access Tips. Issue April 26 th, Welcome to the twelfth edition of Simply Access Tips for 2007. Hi [FirstName], Simply Access Tips Issue 12 2007 April 26 th, 2007 Welcome to the twelfth edition of Simply Access Tips for 2007. Housekeeping as usual is at the end of the Newsletter so, if you need to

More information

DATABASE AUTOMATION USING VBA (ADVANCED MICROSOFT ACCESS, X405.6)

DATABASE AUTOMATION USING VBA (ADVANCED MICROSOFT ACCESS, X405.6) Technology & Information Management Instructor: Michael Kremer, Ph.D. Database Program: Microsoft Access Series DATABASE AUTOMATION USING VBA (ADVANCED MICROSOFT ACCESS, X405.6) AGENDA 3. Executing VBA

More information

Simply Access Tips. Issue February 2 nd 2009

Simply Access Tips. Issue February 2 nd 2009 Hi [FirstName], Simply Access Tips Issue 02 2009 February 2 nd 2009 Welcome to the second edition of Simply Access Tips for 2009. Housekeeping, as usual, is at the end of the Newsletter so; if you need

More information

LmÉPï C Á npï À ƵÀ ïì itech Analytic Solutions

LmÉPï C Á npï À ƵÀ ïì itech Analytic Solutions LmÉPï C Á npï À ƵÀ ïì itech Analytic Solutions No. 9, 1st Floor, 8th Main, 9th Cross, SBM Colony, Brindavan Nagar, Mathikere, Bangalore 560 054 Email: itechanalytcisolutions@gmail.com Website: www.itechanalytcisolutions.com

More information

How To Trigger a Relay Group From an Input

How To Trigger a Relay Group From an Input In GuardPointPro it is possible to fire a group of relays across multiple controllers from a signal to a single input This guide explains the steps: Grouping the outputs [Relays] 1. Go to the menu Event

More information

VBA Collections A Group of Similar Objects that Share Common Properties, Methods and

VBA Collections A Group of Similar Objects that Share Common Properties, Methods and VBA AND MACROS VBA is a major division of the stand-alone Visual Basic programming language. It is integrated into Microsoft Office applications. It is the macro language of Microsoft Office Suite. Previously

More information

Not For Sale. Using and Writing Visual Basic for Applications Code. Creating VBA Code for the Holland Database. Case Belmont Landscapes

Not For Sale. Using and Writing Visual Basic for Applications Code. Creating VBA Code for the Holland Database. Case Belmont Landscapes Objectives Tutorial 11 Session 11.1 Learn about Function procedures (functions), Sub procedures (subroutines), and modules Review and modify an existing subroutine in an event procedure Create a function

More information

Fundamental Microsoft Jet SQL for Access 2000

Fundamental Microsoft Jet SQL for Access 2000 Fundamental Microsoft Jet SQL for Access 2000 (Microsoft Access 2000 Technical... Pagina 1 di 13 MSDN Home > MSDN Library > Office Solutions Development > Access 2000 > Technical Articles Fundamental Microsoft

More information

Respond to Errors and Unexpected Conditions

Respond to Errors and Unexpected Conditions Respond to Errors and Unexpected Conditions Callahan Chapter 7 Practice Time Artie s List Loose Ends ensure that frmrestaurant s module has Option Explicit modify tblrestaurant field sizes Restaurant -

More information

Creating a Crosstab Query in Design View

Creating a Crosstab Query in Design View Procedures LESSON 31: CREATING CROSSTAB QUERIES Using the Crosstab Query Wizard box, click Crosstab Query Wizard. 5. In the next Crosstab Query the table or query on which you want to base the query. 7.

More information

Manual Vba Access 2010 Recordset Findfirst

Manual Vba Access 2010 Recordset Findfirst Manual Vba Access 2010 Recordset Findfirst The Recordset property returns the recordset object that provides the data being browsed in a form, report, list box control, or combo box control. If a form.

More information

Access VBA LinkedIn Introduces object oriented programming and provides a foundation in the Access object model and the Visual Basic for Applications

Access VBA LinkedIn Introduces object oriented programming and provides a foundation in the Access object model and the Visual Basic for Applications Access VBA LinkedIn Introduces object oriented programming and provides a foundation in the Access object model and the Visual Basic for Applications VBA programming language. Excel Power Programming with

More information

Excel Macro Record and VBA Editor. Presented by Wayne Wilmeth

Excel Macro Record and VBA Editor. Presented by Wayne Wilmeth Excel Macro Record and VBA Editor Presented by Wayne Wilmeth 1 What Is a Macro? Automates Repetitive Tasks Written in Visual Basic for Applications (VBA) Code Macro Recorder VBA Editor (Alt + F11) 2 Executing

More information

Outline. Writing Functions and Subs. Review Immediate (1-line) Errors. Quiz Two on Thursday (2/23) Same Code Without Option Explicit

Outline. Writing Functions and Subs. Review Immediate (1-line) Errors. Quiz Two on Thursday (2/23) Same Code Without Option Explicit Writing Functions and Subs Larry Caretto Mechanical Engineering 209 Computer Programming for Mechanical Engineers February 21, 2017 Outline Review Debugging and Option Explicit What are functions and subs?

More information

This chapter is intended to take you through the basic steps of using the Visual Basic

This chapter is intended to take you through the basic steps of using the Visual Basic CHAPTER 1 The Basics This chapter is intended to take you through the basic steps of using the Visual Basic Editor window and writing a simple piece of VBA code. It will show you how to use the Visual

More information

An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is

An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is InputBox( ) Function An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is A = InputBox ( Question or Phrase, Window Title, ) Example1: Integer:

More information

Agenda. First Example 24/09/2009 INTRODUCTION TO VBA PROGRAMMING. First Example. The world s simplest calculator...

Agenda. First Example 24/09/2009 INTRODUCTION TO VBA PROGRAMMING. First Example. The world s simplest calculator... INTRODUCTION TO VBA PROGRAMMING LESSON2 dario.bonino@polito.it Agenda First Example Simple Calculator First Example The world s simplest calculator... 1 Simple Calculator We want to design and implement

More information

Excel Programming with VBA (Macro Programming) 24 hours Getting Started

Excel Programming with VBA (Macro Programming) 24 hours Getting Started Excel Programming with VBA (Macro Programming) 24 hours Getting Started Introducing Visual Basic for Applications Displaying the Developer Tab in the Ribbon Recording a Macro Saving a Macro-Enabled Workbook

More information

VBA Excel 2013/2016. VBA Visual Basic for Applications. Learner Guide

VBA Excel 2013/2016. VBA Visual Basic for Applications. Learner Guide VBA Visual Basic for Applications Learner Guide 1 Table of Contents SECTION 1 WORKING WITH MACROS...5 WORKING WITH MACROS...6 About Excel macros...6 Opening Excel (using Windows 7 or 10)...6 Recognizing

More information

variables programming statements

variables programming statements 1 VB PROGRAMMERS GUIDE LESSON 1 File: VbGuideL1.doc Date Started: May 24, 2002 Last Update: Dec 27, 2002 ISBN: 0-9730824-9-6 Version: 0.0 INTRODUCTION TO VB PROGRAMMING VB stands for Visual Basic. Visual

More information

Download the files from you will use these files to finish the following exercises.

Download the files from  you will use these files to finish the following exercises. Exercise 6 Download the files from http://www.peter-lo.com/teaching/x4-xt-cdp-0071-a/source6.zip, you will use these files to finish the following exercises. 1. This exercise will guide you how to create

More information

First of all, model the component according to the dimensions shown below. Finally save the model as Flange-cutaway.

First of all, model the component according to the dimensions shown below. Finally save the model as Flange-cutaway. Configurations In the following tutorial we will look at using configurations. Configurations may also be used to create different versions of a component for display purposes. Configuration may also be

More information

Using loops and debugging code

Using loops and debugging code Using loops and debugging code Chapter 7 Looping your code pp. 103-118 Exercises 7A & 7B Chapter 8 Fixing Bugs pp. 119-132 Exercise 8 Chapter 7 Looping your code Coding a For loop Coding a Do loop Chapter

More information

x, with a range of 1-50 (You can use the randbetween command on excel)

x, with a range of 1-50 (You can use the randbetween command on excel) HW 2, Part 1 Question 1 (In EXCEL) Create a data set with the following characteristics: Sample size: 100 One independent variable: x, with a range of 1-50 (You can use the randbetween command on excel)

More information

Proficy* HMI/SCADA - ifix W RITING S CRIPTS

Proficy* HMI/SCADA - ifix W RITING S CRIPTS Proficy* HMI/SCADA - ifix W RITING S CRIPTS Version 5.5 January 2012 All rights reserved. No part of this publication may be reproduced in any form or by any electronic or mechanical means, including photocopying

More information

Copyright. Trademarks Attachmate Corporation. All rights reserved. USA Patents Pending. WRQ ReflectionVisual Basic User Guide

Copyright. Trademarks Attachmate Corporation. All rights reserved. USA Patents Pending. WRQ ReflectionVisual Basic User Guide PROGRAMMING WITH REFLECTION: VISUAL BASIC USER GUIDE WINDOWS XP WINDOWS 2000 WINDOWS SERVER 2003 WINDOWS 2000 SERVER WINDOWS TERMINAL SERVER CITRIX METAFRAME CITRIX METRAFRAME XP ENGLISH Copyright 1994-2006

More information

Microsoft Excel 2016 Level 1

Microsoft Excel 2016 Level 1 Microsoft Excel 2016 Level 1 One Day Course Course Description You have basic computer skills such as using a mouse, navigating through windows, and surfing the Internet. You have also used paper-based

More information

Higher Computing Science Software Design and Development - Programming Summary Notes

Higher Computing Science Software Design and Development - Programming Summary Notes Higher Computing Science Software Design and Development - Programming Summary Notes Design notations A design notation is the method we use to write down our program design. Pseudocode is written using

More information

Lab Sheet 4.doc. Visual Basic. Lab Sheet 4: Non Object-Oriented Programming Practice

Lab Sheet 4.doc. Visual Basic. Lab Sheet 4: Non Object-Oriented Programming Practice Visual Basic Lab Sheet 4: Non Object-Oriented Programming Practice This lab sheet builds on the basic programming you have done so far, bringing elements of file handling, data structuring and information

More information

CS130/230 Lecture 12 Advanced Forms and Visual Basic for Applications

CS130/230 Lecture 12 Advanced Forms and Visual Basic for Applications CS130/230 Lecture 12 Advanced Forms and Visual Basic for Applications Friday, January 23, 2004 We are going to continue using the vending machine example to illustrate some more of Access properties. Advanced

More information

edna View: Advanced Techniques

edna View: Advanced Techniques edna View: Advanced Techniques Class Agenda Best Practices Data Structures Sub Procedures & Functions edna Trend Object CHaD Useful Tips Q&A BEST PRACTICES Best Practices Option Explicit Enforces restrictions

More information

Using Visual Studio.NET: IntelliSense and Debugging

Using Visual Studio.NET: IntelliSense and Debugging DRAFT Simon St.Laurent 3/1/2005 2 Using Visual Studio.NET: IntelliSense and Debugging Since you're going to be stuck using Visual Studio.NET anyway, at least for this edition of the.net Compact Framework,

More information

17. Introduction to Visual Basic Programming

17. Introduction to Visual Basic Programming 17. Introduction to Visual Basic Programming Visual Basic (VB) is the fastest and easiest way to create applications for MS Windows. Whether you are an experienced professional or brand new to Windows

More information

Visual Programming 1. What is Visual Basic? 2. What are different Editions available in VB? 3. List the various features of VB

Visual Programming 1. What is Visual Basic? 2. What are different Editions available in VB? 3. List the various features of VB Visual Programming 1. What is Visual Basic? Visual Basic is a powerful application development toolkit developed by John Kemeny and Thomas Kurtz. It is a Microsoft Windows Programming language. Visual

More information

Getting started 7. Setting properties 23

Getting started 7. Setting properties 23 Contents 1 2 3 Getting started 7 Introducing Visual Basic 8 Installing Visual Studio 10 Exploring the IDE 12 Starting a new project 14 Adding a visual control 16 Adding functional code 18 Saving projects

More information

Manual Vba Access 2010 Close Form Without Saving

Manual Vba Access 2010 Close Form Without Saving Manual Vba Access 2010 Close Form Without Saving Close form without saving record Modules & VBA. Join Date: Aug 2010 bound forms are a graphic display of the actual field. updating data is automatic. But

More information

Vba Variables Constant and Data types in Excel

Vba Variables Constant and Data types in Excel Vba Variables Constant and Data types in Excel VARIABLES In Excel VBA, variables are areas allocated by the computer memory to hold data. Data stored inside the computer memory has 4 properties: names,

More information

Civil Engineering Computation

Civil Engineering Computation Civil Engineering Computation First Steps in VBA Homework Evaluation 2 1 Homework Evaluation 3 Based on this rubric, you may resubmit Homework 1 and Homework 2 (along with today s homework) by next Monday

More information

6/14/2010. VBA program units: Subroutines and Functions. Functions: Examples: Examples:

6/14/2010. VBA program units: Subroutines and Functions. Functions: Examples: Examples: VBA program units: Subroutines and Functions Subs: a chunk of VBA code that can be executed by running it from Excel, from the VBE, or by being called by another VBA subprogram can be created with the

More information

Control Flow: Loop Statements

Control Flow: Loop Statements Control Flow: Loop Statements A loop repeatedly executes a of sub-statements, called the loop body. Python provides two kinds of loop statements: a for-loop and a while-loop. This exercise gives you practice

More information

MS Excel VBA Class Goals

MS Excel VBA Class Goals MS Excel VBA 2013 Class Overview: Microsoft excel VBA training course is for those responsible for very large and variable amounts of data, or teams, who want to learn how to program features and functions

More information

Manual Vba Access 2010 Recordset Find

Manual Vba Access 2010 Recordset Find Manual Vba Access 2010 Recordset Find Microsoft Access VBA Programming - ADO Recordsets for The Beginners Part 2 Demo. The Recordset property returns the recordset object that provides the data being browsed

More information

Lab 7 Macros, Modules, Data Access Pages and Internet Summary Macros: How to Create and Run Modules vs. Macros 1. Jumping to Internet

Lab 7 Macros, Modules, Data Access Pages and Internet Summary Macros: How to Create and Run Modules vs. Macros 1. Jumping to Internet Lab 7 Macros, Modules, Data Access Pages and Internet Summary Macros: How to Create and Run Modules vs. Macros 1. Jumping to Internet 1. Macros 1.1 What is a macro? A macro is a set of one or more actions

More information

Step 1: Create a totals query to show the total cost price and total sale price of the wine for each supplier.

Step 1: Create a totals query to show the total cost price and total sale price of the wine for each supplier. Hands-On-2: Queries In D1 you used Select queries to extract required information from your database. You used these to list data that met certain criteria and also used totals queries (a special type

More information

Put Final Touches on an Application

Put Final Touches on an Application Put Final Touches on an Application Callahan Chapter 11 Preparing Your Application for Distribution Controlling How Your Application Starts Forms-based bound forms for data presentation dialog boxes Switchboard

More information

MICROSOFT EXCEL 2000 LEVEL 5 VBA PROGRAMMING INTRODUCTION

MICROSOFT EXCEL 2000 LEVEL 5 VBA PROGRAMMING INTRODUCTION MICROSOFT EXCEL 2000 LEVEL 5 VBA PROGRAMMING INTRODUCTION Lesson 1 - Recording Macros Excel 2000: Level 5 (VBA Programming) Student Edition LESSON 1 - RECORDING MACROS... 4 Working with Visual Basic Applications...

More information

Smart Access. CROSSTAB queries are helpful tools for displaying data in a tabular. Automated Excel Pivot Reports from Access. Mark Davis. vb123.

Smart Access. CROSSTAB queries are helpful tools for displaying data in a tabular. Automated Excel Pivot Reports from Access. Mark Davis. vb123. vb123.com Smart Access Solutions for Microsoft Access Developers Automated Excel Pivot Reports from Access Mark Davis 2000 2002 Excel pivot reports are dynamic, easy to use, and have several advantages

More information

Iteration -- Once Is Not Enough

Iteration -- Once Is Not Enough Iteration -- Once Is Not Enough ),7 Congratulations! The Day Find project is done! -- Reflect This is a significant accomplishment Understand a fundamental algorithm -- binary search Know how to search

More information

Excel VBA Variables, Data Types & Constant

Excel VBA Variables, Data Types & Constant Excel VBA Variables, Data Types & Constant Variables are used in almost all computer program and VBA is no different. It's a good practice to declare a variable at the beginning of the procedure. It is

More information

Microsoft Excel 2010 Level 1

Microsoft Excel 2010 Level 1 Microsoft Excel 2010 Level 1 One Day Course Course Description You have basic computer skills such as using a mouse, navigating through windows, and surfing the Internet. You have also used paper-based

More information

Personal Directory PC Utility Reference Guide

Personal Directory PC Utility Reference Guide Introduction The Personal Directory PC Utility provides a faster, easier way to create or modify a Personal Directory for an Avaya 3904 or 3905 Digital Deskphone. You can enter names and numbers into a

More information

BASIC EXCEL SYLLABUS Section 1: Getting Started Section 2: Working with Worksheet Section 3: Administration Section 4: Data Handling & Manipulation

BASIC EXCEL SYLLABUS Section 1: Getting Started Section 2: Working with Worksheet Section 3: Administration Section 4: Data Handling & Manipulation BASIC EXCEL SYLLABUS Section 1: Getting Started Unit 1.1 - Excel Introduction Unit 1.2 - The Excel Interface Unit 1.3 - Basic Navigation and Entering Data Unit 1.4 - Shortcut Keys Section 2: Working with

More information

Acknowledgments Introduction. Chapter 1: Introduction to Access 2007 VBA 1. The Visual Basic Editor 18. Testing Phase 24

Acknowledgments Introduction. Chapter 1: Introduction to Access 2007 VBA 1. The Visual Basic Editor 18. Testing Phase 24 Acknowledgments Introduction Chapter 1: Introduction to Access 2007 VBA 1 What Is Access 2007 VBA? 1 What s New in Access 2007 VBA? 2 Access 2007 VBA Programming 101 3 Requirements-Gathering Phase 3 Design

More information

SAP NETWEAVER DECISION SERVICE MANAGEMENT A PARADIGM SHIFT

SAP NETWEAVER DECISION SERVICE MANAGEMENT A PARADIGM SHIFT SAP NETWEAVER DECISION SERVICE MANAGEMENT A PARADIGM SHIFT CD160 Exercises / Solutions Alexander Held, SAP Deutschland AG & Co. KG Carsten Ziegler, SAP AG 2 In these exercises, we want to set up a managed

More information

BASIC MACROINSTRUCTIONS (MACROS)

BASIC MACROINSTRUCTIONS (MACROS) MS office offers a functionality of building complex actions and quasi-programs by means of a special scripting language called VBA (Visual Basic for Applications). In this lab, you will learn how to use

More information

Create a new form. To create a form from a new or existing spreadsheet: 1. Click the Tools drop down menu and select Create a form.

Create a new form. To create a form from a new or existing spreadsheet: 1. Click the Tools drop down menu and select Create a form. Create a new form You can choose Google Forms when creating a new doc from Google Drive. You can also create a new form from a Google Sheet or from a template. To create a form within Google Drive: Click

More information

Manual Vba Access 2010 Close Form Without Saving Record

Manual Vba Access 2010 Close Form Without Saving Record Manual Vba Access 2010 Close Form Without Saving Record I have an Access 2010 database which is using a form frmtimekeeper to keep Then when the database is closed the close sub writes to that same record

More information

Access Forms Masterclass 5 Create Dynamic Titles for Your Forms

Access Forms Masterclass 5 Create Dynamic Titles for Your Forms Access Forms Masterclass 5 Create Dynamic Titles for Your Forms Published: 13 September 2018 Author: Martin Green Screenshots: Access 2016, Windows 10 For Access Versions: 2007, 2010, 2013, 2016 Add a

More information

Excel VBA for Absolute Beginners

Excel VBA for Absolute Beginners Applied Technology Group Sdn Bhd (1012178-W) W-5-3, Subang Square Business Centre, Jalan SS15/4G, 47500 Subang Jaya, Selangor, Malaysia. Tel: (+603) 5634 7905 Fax: (+603) 5637 9945 Email: admin@apptechgroups.net

More information

Respond to Data Entry Events

Respond to Data Entry Events Respond to Data Entry Events Callahan Chapter 4 Understanding Form and Control Events Developer s Goal make data entry easy, fast, complete, accurate Many form- and control-level events occur as user works

More information

ChronoForms v3.0 Tutorials #5 Saving data to the database.

ChronoForms v3.0 Tutorials #5 Saving data to the database. ChronoForms v3.0 Tutorials #5 Saving data to the database CHRONO ENGINE www.chronoengine.com Saving data to the database This tutorial tells you how to create a database table to save the data from your

More information

Excel & Visual Basic for Applications (VBA)

Excel & Visual Basic for Applications (VBA) Class meeting #18 Monday, Oct. 26 th GEEN 1300 Introduction to Engineering Computing Excel & Visual Basic for Applications (VBA) user interfaces o on-sheet buttons o InputBox and MsgBox functions o userforms

More information

KEYWORDS DDE GETOBJECT PATHNAME CLASS VB EDITOR WITHEVENTS HMI 1.0 TYPE LIBRARY HMI.TAG

KEYWORDS DDE GETOBJECT PATHNAME CLASS VB EDITOR WITHEVENTS HMI 1.0 TYPE LIBRARY HMI.TAG Document Number: IX_APP00113 File Name: SpreadsheetLinking.doc Date: January 22, 2003 Product: InteractX Designer Application Note Associated Project: GetObjectDemo KEYWORDS DDE GETOBJECT PATHNAME CLASS

More information

Introduction. Opening and Closing Databases. Access 2010 Managing Databases and Objects. Video: Working with Databases in Access 2010

Introduction. Opening and Closing Databases. Access 2010 Managing Databases and Objects. Video: Working with Databases in Access 2010 Access 2010 Managing Databases and Objects Introduction Page 1 Each Access database consists of multiple objects that let you interact with data. Databases can include forms for entering data, queries

More information

Version 7.0. for WINDOWS NT 4.0 for WINDOWS 98 for WINDOWS 95. Programming with Reflection: Visual Basic User Guide.

Version 7.0. for WINDOWS NT 4.0 for WINDOWS 98 for WINDOWS 95. Programming with Reflection: Visual Basic User Guide. Version 7.0 for WINDOWS NT 4.0 for WINDOWS 98 for WINDOWS 95 Programming with Reflection: Visual Basic User Guide WRQ Reflection Copyright 1998 by WRQ, Inc. All rights reserved. No part of this publication

More information

CS 200. Lecture 07. Excel Scripting. Miscellaneous Notes

CS 200. Lecture 07. Excel Scripting. Miscellaneous Notes CS 200 Lecture 07 1 Abbreviations aka Also Known As Miscellaneous Notes CWS Course Web Site (http://www.student.cs.uwaterloo.ca/~cs200) VBE Visual Basic Editor intra- a prefix meaning within thus intra-cellular

More information

VBA-Session 6. Conditional Logic. If... Then

VBA-Session 6. Conditional Logic. If... Then VBA-Session 6 Conditional Logic If... Then In logic, a conditional is a statement formed by combining two sentences (or facts) using the words "if... then." It is about saying what has to happen IF a certain

More information

Copyrighted Material. Copyrighted. Material. Copyrighted

Copyrighted Material. Copyrighted. Material. Copyrighted Properties Basic Properties User Forms Arrays Working with Assemblies Selection Manager Verification and Error Handling Introduction This exercise is designed to go through the process of changing document

More information

VBA Programming: Part I

VBA Programming: Part I VBA Programming: Part I This is a Basic introduction into creating VBA programs Online support: https://support.office.com/en- US/article/create-or-run-a-macro-c6b99036-905c-49a6-818a-dfb98b7c3c9c VBA

More information

Work more efficiently by learning how to automate recurring tasks and create user applications

Work more efficiently by learning how to automate recurring tasks and create user applications V B A ( M A C R O S ) Work more efficiently by learning how to automate recurring tasks and create user applications Prepared by: XL Your Mind Gneisenaustraße 27 40477, Düsseldorf Germany W H A T T O E

More information

CS 200. Lecture 07. Excel Scripting. Excel Scripting. CS 200 Fall 2016

CS 200. Lecture 07. Excel Scripting. Excel Scripting. CS 200 Fall 2016 CS 200 Lecture 07 1 Abbreviations aka Also Known As Miscellaneous Notes CWS Course Web Site (http://www.student.cs.uwaterloo.ca/~cs200) VBE Visual Basic Editor intra- a prefix meaning within thus intra-cellular

More information

CS 200. Lecture 07. Excel Scripting. Miscellaneous Notes

CS 200. Lecture 07. Excel Scripting. Miscellaneous Notes CS 200 Lecture 07 1 Abbreviations aka Also Known As Miscellaneous Notes CWS Course Web Site (http://www.student.cs.uwaterloo.ca/~cs200) VBE Visual Basic Editor intra- a prefix meaning within thus intra-cellular

More information

Excel4apps Web ADI Investigation with Excel4apps Wands version Excel4apps Inc.

Excel4apps Web ADI Investigation with Excel4apps Wands version Excel4apps Inc. Excel4apps Web ADI Investigation with Excel4apps Wands version 5 2014 Excel4apps Inc. Table of Contents 1 Introduction... 3 2 Error... 3 3 Problem Description... 3 4 Cause... 3 5 Conclusion... 4 6 Next

More information

How to design and print cards using a database connection with. emedia CS Software

How to design and print cards using a database connection with. emedia CS Software How to design and print cards using a database connection with emedia CS Software For this exercise, we will use a Database that has been created in EXCEL. The example below shows the database fields populated

More information

Switchboard. Creating and Running a Navigation Form

Switchboard. Creating and Running a Navigation Form Switchboard A Switchboard is a type of form that displays a menu of items that a user can click on to launch data entry forms, reports, queries and other actions in the database. A switchboard is typically

More information

DroidBasic Syntax Contents

DroidBasic Syntax Contents DroidBasic Syntax Contents DroidBasic Syntax...1 First Edition...3 Conventions Used In This Book / Way Of Writing...3 DroidBasic-Syntax...3 Variable...4 Declaration...4 Dim...4 Public...4 Private...4 Static...4

More information

Advanced Financial Modeling Macros. EduPristine

Advanced Financial Modeling Macros. EduPristine Advanced Financial Modeling Macros EduPristine www.edupristine.com/ca Agenda Introduction to Macros & Advanced Application Building in Excel Introduction and context Key Concepts in Macros Macros as recorded

More information

Welcome Pack.

Welcome Pack. Welcome Pack This welcome pack is intended to get you up and running with your new account as smoothly as possible and contains the following information: What is the London Grid for Learning? Accessing

More information

EMu Release Notes. ADO Reports. EMu 5.0. Document Version 1

EMu Release Notes. ADO Reports. EMu 5.0. Document Version 1 EMu Release Notes ADO Reports EMu 5.0 Document Version 1 Contents SECTION 1 ADO Reports 1 Note 1 SECTION 2 Crystal Reports 3 How to create a Crystal ADO Report 3 How to modify a Crystal Report to use

More information

CS 112 Introduction to Computing II. Wayne Snyder Computer Science Department Boston University

CS 112 Introduction to Computing II. Wayne Snyder Computer Science Department Boston University 9/5/6 CS Introduction to Computing II Wayne Snyder Department Boston University Today: Arrays (D and D) Methods Program structure Fields vs local variables Next time: Program structure continued: Classes

More information

Debugging Code in Access 2002

Debugging Code in Access 2002 0672321025 AppA 10/24/01 3:53 PM Page 1 Debugging Code in Access 2002 APPENDIX A IN THIS APPENDIX Setting the Correct Module Options for Maximum Debugging Power 2 Using the Immediate Window 6 Stopping

More information

Introduction to macros

Introduction to macros L E S S O N 7 Introduction to macros Suggested teaching time 30-40 minutes Lesson objectives To understand the basics of creating Visual Basic for Applications modules in Excel, you will: a b c Run existing

More information

Access VBA programming

Access VBA programming Access VBA programming TUTOR: Andy Sekiewicz MOODLE: http://moodle.city.ac.uk/ WEB: www.staff.city.ac.uk/~csathfc/acvba The DoCmd object The DoCmd object is used to code a lot of the bread and butter operations

More information

Alternatives To Custom Dialog Box

Alternatives To Custom Dialog Box Alternatives To Custom Dialog Box Contents VBA Input Box Syntax & Function The Excel InputBox method Syntax The VBA MsgBox Function The Excel GetOpenFilename Method The Excel GetSaveAsFilename Method Reference

More information

20. VB Programming Fundamentals Variables and Procedures

20. VB Programming Fundamentals Variables and Procedures 20. VB Programming Fundamentals Variables and Procedures 20.1 Variables and Constants VB, like other programming languages, uses variables for storing values. Variables have a name and a data type. Array

More information

EXCEL WORKSHOP III INTRODUCTION TO MACROS AND VBA PROGRAMMING

EXCEL WORKSHOP III INTRODUCTION TO MACROS AND VBA PROGRAMMING EXCEL WORKSHOP III INTRODUCTION TO MACROS AND VBA PROGRAMMING TABLE OF CONTENTS 1. What is VBA? 2. Safety First! 1. Disabling and Enabling Macros 3. Getting started 1. Enabling the Developer tab 4. Basic

More information

Exercise Session 6 Computer Architecture and Systems Programming

Exercise Session 6 Computer Architecture and Systems Programming Systems Group Department of Computer Science ETH Zürich Exercise Session 6 Computer Architecture and Systems Programming Herbstsemester 2016 Agenda GDB Outlook on assignment 6 GDB The GNU Debugger 3 Debugging..

More information

Excel Vba Manually Update Links On Open Workbook Don

Excel Vba Manually Update Links On Open Workbook Don Excel Vba Manually Update Links On Open Workbook Don I have a workbook within which there are links to number of other workbooks. b) updating links to workbooks that are already open seems to cause errors.

More information

Excel Vba Manually Update Links On Open Workbook Without Updating

Excel Vba Manually Update Links On Open Workbook Without Updating Excel Vba Manually Update Links On Open Workbook Without Updating When opening the workbook from within a macro, you probably don't want Excel to ask This UpdateLinks property is optional, but without

More information

3 Getting Started with Objects

3 Getting Started with Objects 3 Getting Started with Objects If you are an experienced IDE user, you may be able to do this tutorial without having done the previous tutorial, Getting Started. However, at some point you should read

More information

Personal Directory PC Utility Reference Guide

Personal Directory PC Utility Reference Guide Introduction The PC Utility provides a fast, easy way to create or modify a for an M3904 or M3905 Series Digital Telephone. You can enter names and numbers into a file on your PC, and download (Program)

More information

GEOG 485 GIS Programming and Customization

GEOG 485 GIS Programming and Customization Overview of Project 1 The first three parts of Lesson were surprisingly easy. I come to GEOG 485 with no programming background or experience. In the month preceding this course I worked through the first

More information

Pianola User Guide for Club Members How to analyse your own results and find a partner with Pianola

Pianola User Guide for Club Members How to analyse your own results and find a partner with Pianola Pianola User Guide for Club Members How to analyse your own results and find a partner with Pianola Pianola User Guide Page 1 Contents Introduction... 3 Results... 4 Personal summary Travellers Personal

More information

HPCC - Hrothgar. Getting Started User Guide TotalView. High Performance Computing Center Texas Tech University

HPCC - Hrothgar. Getting Started User Guide TotalView. High Performance Computing Center Texas Tech University HPCC - Hrothgar Getting Started User Guide TotalView High Performance Computing Center Texas Tech University HPCC - Hrothgar 2 Table of Contents *This user guide is under development... 3 1. Introduction...

More information

Building OpenOffice Presentations. Welcome. Stan Reichardt St. Louis Unix Users Grroup 11 August 2004

Building OpenOffice Presentations. Welcome. Stan Reichardt St. Louis Unix Users Grroup 11 August 2004 Building OpenOffice Presentations Welcome Stan Reichardt stan@sluug.org St. Louis Unix Users Grroup 11 August 2004 Outline of Tutorial Assume OpenOffice Already Installed Specifics About This tutorial

More information

Access VBA Fundamentals

Access VBA Fundamentals VBA Made Easy Access VBA Fundamentals Level 1 www.accessallinone.com This guide was prepared for AccessAllInOne.com by: Robert Austin This is one of a series of guides pertaining to the use of Microsoft

More information

END-TERM EXAMINATION

END-TERM EXAMINATION (Please Write your Exam Roll No. immediately) END-TERM EXAMINATION DECEMBER 2006 Exam. Roll No... Exam Series code: 100274DEC06200274 Paper Code : MCA-207 Subject: Front End Design Tools Time: 3 Hours

More information