Chapter 2 Build Your First Project A Step-by-Step Approach 2 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta Eaton.

Slides:



Advertisements
Similar presentations
CS0004: Introduction to Programming Visual Studio 2010 and Controls.
Advertisements

Chapter 1 - VB 2008 by Schneider1 Chapter 1 - An Introduction to Computers and Problem Solving 1.1 An Introduction to Computers 1.2 Windows, Folders, and.
Computers: Tools for an Information Age
Program Flow Charting How to tackle the beginning stage a program design.
Using the Visual Basic Editor Visual Basic for Applications 1.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Technology Education Copyright © 2006 by The McGraw-Hill Companies,
1 An Introduction to Visual Basic Objectives Explain the history of programming languages Define the terminology used in object-oriented programming.
Objectives Machine language vs.. High-level language Procedure-oriented, object-oriented, and event- driven languages Background of Visual Basic VB Integrated.
Copyright © 2001 by Wiley. All rights reserved. Chapter 1: Introduction to Programming and Visual Basic Computer Operations What is Programming? OOED Programming.
Introduction to Programming and Visual Basic
Your Interactive Guide to the Digital World Discovering Computers 2012.
Peter Andreae Computer Science Victoria University of Wellington Copyright: Peter Andreae, Victoria University of Wellington Java Programs COMP 102 #3.
1 ENG236: ENG236: C++ Programming Environment (2) Rocky K. C. Chang THE HONG KONG POLYTECHNIC UNIVERSITY.
Introduction 01_intro.ppt
1 Chapter One A First Program Using C#. 2 Objectives Learn about programming tasks Learn object-oriented programming concepts Learn about the C# programming.
1 Integrated Development Environment Building Your First Project (A Step-By-Step Approach)
A First Program Using C#
Chapter 1 Introduction to Visual Basic Programming and Applications 1 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta.
Visual Basic Chapter 1 Mr. Wangler.
Learning Objectives Data and Information Six Basic Operations Computer Operations Programs and Programming What is Programming? Types of Languages Levels.
Microsoft Visual Basic 2005: Reloaded Second Edition
COMPUTER PROGRAMMING Source: Computing Concepts (the I-series) by Haag, Cummings, and Rhea, McGraw-Hill/Irwin, 2002.
Chapter 1 P. 1 Writing Windows applications with Visual Basic Figure 1.1 The first program works as follows: (These operations can be performed in any.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
An Introduction to Visual Basic
1 Documenting Your Project. 2 Documenting your Project Insert Banner Comments in your code Comment - coding statement used by humans not the compiler.
Introduction to Visual Basic. Quick Links Windows Application Programming Event-Driven Application Becoming familiar with VB Control Objects Saving and.
Chapter 1: A First Program Using C#. Programming Computer program – A set of instructions that tells a computer what to do – Also called software Software.
Appendices A - F A-F Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta Eaton.
Chapter 3: Completing the Problem- Solving Process and Getting Started with C++ Introduction to Programming with C++ Fourth Edition.
Automating Database Processing Chapter 6. Chapter Introduction Design and implement user-friendly menu – Called navigation form Macros – Automate repetitive.
Java Programming, Second Edition Chapter One Creating Your First Java Program.
 Application – another name for a program.  Interface – is what appears on the screen when the application is running.  Program Code – is instructions.
Tutorial 11 Five windows included in the Visual Basic Startup Screen Main Form Toolbox Project Explorer (Project) Properties.
Irwin/McGraw-Hill Copyright© 2000 by the McGraw-Hill Companies, Inc. PowerPoint® Presentation to accompany prepared by James T. Perry University of San.
CHAPTER TWO INTRODUCTION TO VISUAL BASIC © Prepared By: Razif Razali 1.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 8 Debugging, Creating Executable Files, and Distributing a Windows Application.
Microsoft Visual Basic 2005 BASICS Lesson 1 A First Look at Microsoft Visual Basic.
1.
 Programming - the process of creating computer programs.
Microsoft Visual Basic 2008: Reloaded Third Edition Chapter One An Introduction to Visual Basic 2008.
Chapter 27 Getting “Web-ified” (Web Applications) Clearly Visual Basic: Programming with Visual Basic nd Edition.
Chapter 1 Introduction to Visual Basic Programming and Applications 1 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta.
Visual Basic.Net. Software to Install Visual Studio 2005 Professional Edition (Requires Windows XP Pro) MSDN Library for Visual Studio 2005 Available.
Microsoft Visual Basic 2012: Reloaded Fifth Edition Chapter One An Introduction to Visual Basic 2012.
Chapter 1: Introduction to Computers and Programming.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 1 An Introduction to Visual Basic.NET and Program Design.
Introduction to Computer Programming Concepts M. Uyguroğlu R. Uyguroğlu.
Some of the utilities associated with the development of programs. These program development tools allow users to write and construct programs that the.
Chapter 2 Build Your First Project A Step-by-Step Approach 2 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta Eaton.
COMPREHENSIVE Excel Tutorial 12 Expanding Excel with Visual Basic for Applications.
Chapter 1 Introduction to Visual Basic
Introduction To Visual Basic 6
Visual Basic.NET Windows Programming
Development Environment
Visual Basic Code & No.: CS 218
Introduction to Computer CC111
Chapter 2- Visual Basic Schneider
An Introduction to Programming and VB.NET
1. Introduction to Visual Basic
Hands-on Introduction to Visual Basic .NET
CIS16 Application Development Programming with Visual Basic
Chapter 2- Visual Basic Schneider
Chapter 2- Visual Basic Schneider
Chapter 4 Enhancing the Graphical User Interface
Programming Logic and Design Eighth Edition
Presentation transcript:

Chapter 2 Build Your First Project A Step-by-Step Approach 2 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta Eaton

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.2 Objectives  Describe compilers, interpreters, source code files, pseudo code files, native code files, and executable files.  Describe the steps in building an application program.  Describe the steps in building a project with Visual Basic.  Create a Visual Basic project following the step-by-step approach.

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.3 Programmer’s Lingo Program - detailed set of instructions for a computer Programming Language - tool used to create a program; defined by semantics and syntax Semantics - the meaning of words in a language Syntax - rules for combining symbols of a language

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.4 Programmer’s Lingo Source Code (code) - program you write using a programming language Interpreter - translates and executes source code statement by statement

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.5 Programmer’s Lingo Interpreter Process

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.6 Programmer’s Lingo Compiler - translates source code into an executable file Executable file - standalone file that runs outside the Visual Basic environment; Used to distribute most Windows applications Package and Deployment Wizard (Application Setup Wizard in VB5) - creates all the files necessary to distribute your projects

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.7 Programmer’s Lingo Compiler Process

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.8 Programmer’s Lingo Object Code - intermediate step between source code and native code Native Code (machine language) -instructions the computer can execute directly Dynamic Link Library (DLL) - translates instructions in executable file at runtime

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.9 Steps in Building a Project 1. Define the Problem 2. Design and Plan 3. Build the Program 4. Run the Program 5. Test and Debug 6. Document Your Program 7. Compile and Distribute Your Program

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.10 Steps in Building a Project Step 1 - Define the Problem Decide exactly what problem you want to solve Or task you want to perform Understand what needs to be done Specification - details of your problem definition

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.11 Steps in Building a Project Step 2 - Design and Plan Most important step of the process Find a step-by-step solution to your problem Algorithm - step-by-step solution to a problem Design User Interface; draw sketches of screens, graphics, text and button

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.12 Steps in Building a Project Step 3 - Build the Program Translate your solution using the programming language Coding - writing a program in a programming language Create the user interface, set properties Write code for commands and instructions

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.13 Steps in Building a Project Step 4 - Run the Program Run the program in the programming environment Visual Basic Interactive Development Environment for VB Simply click the Start button

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.14 Steps in Building a Project Step 5 - Test and Debug Testing - running your program and looking for errors Debugging - process of removing errors from a program Bug - error in a program Repeat until your program runs as designed

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.15 Steps in Building a Project Step 6 - Document your Program Very important if program will be updated in the future Documentation - consists of notes and materials that describes a program Organize the documentation

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.16 Steps in Building a Project Step 7 - Compile and Distribute Proceed to this step only after all bugs have been discovered and removed Distribute program to end user End User - the target audience for your final program

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.17 Steps in Building a Deck 1. Define the Problem - deck for grill, table and 4 chairs 2. Design and Plan - sketch a floor plan 3. Build the Deck - oops, forgot stairs 4-5. Run, Test, and Debug - as we built 6. Document the Work - receipts and plans 7. Compile and Distribute - invite friends for a cookout to share and enjoy new deck

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.18 Critique the Process  Programming is a building process  Make-or-buy decision - build it or buy it  Look for flaws before building  Much easier and less expensive to correct flaws during specification step  Work smart; gather documentation throughout process  Test and debug to avoid dissatisfied customers and potential lawsuits

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.19 Build a Visual Basic Application

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.20 Build Your First Application Hands-On Exercise 1 Create a New Project Set Visual Basic Options Restart Visual Basic Create the Initial Screen Create the Final Screen Add an Image to the Final Screen Save Your Project Run Your Project Close the Project and Exit Visual Basic

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.21 Using the Code Editor GUI (Graphical User Interface) - forms and windows that the user sees Property - a characteristic or attribute of an object such as color and size Event - a user action such as clicking a button Code Editor window - editor specially designed to help you when writing code

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.22 Testing and Debugging  Humans are not perfect  Rarely code programs right the first time  Test to find problems  Debug to correct problems

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.23 Banner Comments ‘************************************* ‘ Programmer: Carlotta Eaton ‘ Date: June 30, 1998 ‘ Source: Hello World.vbp ‘ ID: Chapter 2 Hands-On 1 ‘ Purpose: Practice steps to create ‘ a Visual Basic project ‘ Inputs: None ‘ Returns: None ‘***************************************

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.24 Documenting Your Project  Follow Code Conventions, and Print your Code Conventions make your code easier to read and understand Use block indenting Print code and put in documentation folder

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.25 Distributing Your Project  Remove all bugs first  Create an executable file Pull down File menu, and select Make Project exe command or Use Package and Deployment Wizard (previously called Setup Wizard)

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.26 Summary...  Key terms defined such as compiler and executable file  Use a systematic process to create a Visual Basic project  Spend more time planning and designing and less time writing, testing and debugging

Exploring MS Visual Basic 6 Copyright 1999 Prentice-Hall, Inc.27 Summary Step-by-Step Process 1. Define the problem 2. Design and Plan the Solution 3. Build the Program 4. Run the Program 5. Test and Debug 6. Document your project 7. Compile and Distribute