Control Your Application Sequence, Selection, and Repetition.

Slides:



Advertisements
Similar presentations
Structured Design The Structured Design Approach (also called Layered Approach) focuses on the conceptual and physical level. As discussed earlier: Conceptual.
Advertisements

VISUAL BASIC Visual Basic is derived from the Basic language (Beginner’s All-Purpose Symbolic Instruction Code) Visual Basic uses an event-driven programming.
Microsoft Visual Basic: Reloaded Chapter Seven More on the Repetition Structure.
Tonight’s JavaScript Topics 1 Conditional Statements: if and switch The Array Object Looping Statements: for, while and do-while.
Clearly Visual Basic: Programming with Visual Basic 2008 Chapter 9 Decisions, Decisions, Decisions.
Chapter 3 Programming Fundamentals Writing Code 3 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta Eaton.
Microsoft Excel 2003 Illustrated Complete with Excel Programming.
VBA Programming Part One. Our Dartmouth Legacy 10 INPUT "What is your name: "; U$ 20 PRINT "Hello "; U$ 25 REM 30 INPUT "How many stars do you want: ";
Program Development and Programming Languages
Repeating Program Instructions Chapter Microsoft Visual Basic.NET: Reloaded 1.
Exploring Microsoft Excel 2002 Chapter 8 Chapter 8 Automating Repetitive Tasks: Macros and Visual Basic for Applications By Robert T. Grauer Maryann Barber.
Programming with Microsoft Visual Basic th Edition
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.
CS 0004 –Lecture 8 Jan 24, 2011 Roxana Gheorghiu.
Chapter 4: The Selection Structure
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.
Chapter 3 Programming Fundamentals Writing Code 3 Exploring Microsoft Visual Basic 6.0 Copyright © 1999 Prentice-Hall, Inc. By Carlotta Eaton.
Chapter 11: Introduction to the Visual Basic Environment Spreadsheet-Based Decision Support Systems Prof. Name Position (123) University.
Microsoft Visual Basic 2010: Reloaded Fourth Edition Chapter Six Repeating Program Instructions.
1 Documenting Your Project. 2 Documenting your Project Insert Banner Comments in your code Comment - coding statement used by humans not the compiler.
Microsoft Visual Basic 2010: Reloaded Fourth Edition Chapter Five More on the Selection Structure.
Automating Database Processing Chapter 6. Chapter Introduction Design and implement user-friendly menu – Called navigation form Macros – Automate repetitive.
Chapter 12: How Long Can This Go On?
Microsoft Visual Basic 2010: Reloaded Fourth Edition Chapter Seven More on the Repetition Structure.
Instructors begin using McGraw-Hill’s Homework Manager by creating a unique class Web site in the system. The Class Homepage becomes the entry point for.
1 CC111 Lec9 : Visual Basic Visual Basic (3) Lecture 9.
Enhancing the Graphical User Interface Multiple Forms, Controls, and Menus.
Copyright © 2001 by Wiley. All rights reserved. Chapter 4: The Selection Process in Visual Basic Selection Process Two Alternative Structure If..Then..ElseIf.
Copyright © 2001 by Wiley. All rights reserved. Chapter 2: Using Visual Basic to Create a First Project Getting Started with VB Development Environment.
 Application – another name for a program.  Interface – is what appears on the screen when the application is running.  Program Code – is instructions.
Program Design and Coding
Microsoft Visual Basic 2012 CHAPTER THREE Program Design and Coding.
Microsoft Visual Basic 2010 CHAPTER THREE Program Design and Coding.
Cosc175/testing1 Testing Software errors are costly GIGO Preventing Errors –Echo checking –Range and limit checking –Defensive programming.
Problem Solving Techniques. Compiler n Is a computer program whose purpose is to take a description of a desired program coded in a programming language.
1 Week 6 The Repetition Structure. 2 The Repetition Structure (Looping) Lesson A Objectives After completing this lesson, you will be able to:  Code.
Controlling Execution Programming Right from the Start with Visual Basic.NET 1/e 8.
Statements That Repeat. For...Next Loop Structure For counter = start To end Step increment statements Next counter Where Counter is tested to see if.
Tutorial 6 The Repetition Structure
Microsoft Visual Basic 2008: Reloaded Third Edition Chapter Six The Do Loop and List Boxes.
Chapter 5: More on the Selection Structure Programming with Microsoft Visual Basic 2005, Third Edition.
Visual Basic Programming
Programming with Microsoft Visual Basic th Edition
Practical Programming COMP153-08S Week 5 Lecture 1: Screen Design Subroutines and Functions.
Introduction to Problem Solving and Control Statements.
Exploring Microsoft Access Chapter 7 Building Applications: The Switchboard, Macros, and Prototyping.
Chapter 15 I’m on the Inside; You’re on the Outside (Nested Loops) Clearly Visual Basic: Programming with Visual Basic nd Edition.
Programming with Microsoft Visual Basic 2008 Fourth Edition Chapter Eight String Manipulation.
Clearly Visual Basic: Programming with Visual Basic 2008 Chapter 16 I’m on the Inside; You’re on the Outside.
Copyright (c) 2003 by Prentice Hall Provided By: Qasim Al-ajmi Chapter 2 Introduction to Visual Basic Programming Visual Basic.NET.
Chapter 3 I Need a Tour Guide (Introduction to Visual Basic 2010) Clearly Visual Basic: Programming with Visual Basic nd Edition.
STEP 3- DEVELOP AN ALGORITHM At this stage we break down the problem into simple manageable steps so that they can be handled easily.
Loop and repetition. Today Passing values to and back from Sub procedures Option Buttons Do While Loops For Loops Population Growth.
TOOLBOX. The Toolbox Intrinsic Controls - always included in the Toolbox ActiveX Controls - separate files with ocx file extension Insertable Objects.
Chapter Five More on the Selection Structure Programming with Microsoft Visual Basic th Edition.
Dani Vainstein1 VBScript Session 5. Dani Vainstein2 What we learn last session? Branching Branching using If … Then … Else statement. Branching using.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 6 Looping and Multiple Forms.
Course ILT Using complex selection structures Unit objectives Include radio buttons and check boxes in an interface, create and call a user- defined Sub.
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.
Customizing the Quick Access Toolbar in Microsoft Office
Numbering System TODAY AND TOMORROW 11th Edition
Exploring Microsoft Excel
VISUAL BASIC FINAL PROGRAMMING PROJECT
Lecture Set 3 Introduction to Visual Basic Concepts
Chapter 2- Visual Basic Schneider
True or False: {image} is one-to-one function.
Console.WriteLine(“Good luck!”);
Chapter 3 Programming Fundamentals
True or False True or False
Presentation transcript:

Control Your Application Sequence, Selection, and Repetition

Controlling your Application Sequence –Functions and Procedures Selection –If...Then...Else statement –Select Case statement Repetition –For...Next Loop statement –For Each...Next statement –Do Loops

The If Statement Example: If UserAnswer = CorrectAnswer Then imgSimle.Visible = True Else imgFrown.Visible = True End If

The Select Case Statement Select Case Weapon Case “Rock” txtMessage = “Rock crushed scissors.” Case “Scissors” txtMessage = “Scissors cut paper.” Case “Paper” txtMessage = “Paper covers rock.” End Select

Learning to Add Project Specification for the Game –purpose of the game is to practice addition skills –use numbers between 0 and 9 –user is a pre-school age child, in kindergarten, or in first grade –user may not yet know how to read –game should give visual feedback indicating correct or incorrect answer

Learning to Add Game Reward for correct answer

Learning to Add Game Image for incorrect answer

Design the User Interface Prototype - a partially completed version of an application that demonstrates the “ look and feel ” of the finished product Usability Testing - end user or client tests design of user interface using a prototype

Making Decisions with the Learning to Add Game Hands-On Exercise 2 (p ) –Create the Learning to Add Project –Add Controls to Display the Problem –Set Common Properties –Set Individual Control Properties –Add More Images and Set Properties –Add Picture Box Controls for Icon Buttons

Making Decisions with the Learning to Add Game Hands-On Exercise 2 (continued) –Add Banner Comments –Add the Load Form Procedure –Add the Checkmark Picture Procedure –Add the Arrow Picture Procedure –Run and Save your Project –Test and Debug your Project –Print your Project Code and Exit

End of Lecture