CS 2340 Programming in VB.NET Instructor: Dr. Qi Yang Office: 213 Ullrich Phone: 342-1418 Email: YangQ 1.

Slides:



Advertisements
Similar presentations
Information System Design Lab 5&6. User Interface Design.
Advertisements

Introduction to Visual Basic.NET Uploaded By: M.Sheraz anjum.
CS0004: Introduction to Programming Visual Studio 2010 and Controls.
Visual Basic 2010 How to Program. © by Pearson Education, Inc. All Rights Reserved.2.
Visual Basic 2010 How to Program Reference: Instructor: Maysoon Bin Duwais slides Visual Basic 2010 how to program by Deitel © by Pearson Education,
Introduction to Visual Basic Programming. Lecture Outline History What is Visual Basic First Look at the VB 6.0 Environment Some VB Terminology Our first.
1 Introduction to the Visual Studio.NET IDE Powerpoint slides modified from Deitel & Deitel.
1 An Introduction to Visual Basic Objectives Explain the history of programming languages Define the terminology used in object-oriented programming.
Introduction to Visual Basic. What is Visual Basic? An environment for developing Windows applications Components –A GUI (Graphical User Interface - gooey)
Instructor: Adil Ibrahim Office: 212 Ullrich Phone: ibrahima 1.
Microsoft Visual Basic 2010: Reloaded Fourth Edition Chapter One An Introduction to Visual Basic 2010.
Getting Started Example ICS2O curriculum
Visual Basic Fundamental Concepts. Integrated Development Enviroment Generates startup form for new project on which to place controls. Features toolbox.
CS 2340: Programming in VB Instructor: Dr. Qi Yang Office: 213 Ullrich Phone: YangQ 1.
Visual Basic 2008 Express Edition The IDE. Visual Basic 2008 Express The Start Page Recent Projects Open an existing project Create a New Project.
Introduction to VB.NET Tonga Institute of Higher Education.
BIL528 – Bilgisayar Programlama II Introduction 1.
Microsoft Visual Basic 2005: Reloaded Second Edition
Introduction to Graphical User Interfaces. Objectives * Students should understand what a procedural program is. * Students should understand what an.
Introduction to Visual Basic. Quick Links Windows Application Programming Event-Driven Application Becoming familiar with VB Control Objects Saving and.
IE 411/511: Visual Programming for Industrial Applications
CSCI 3328 Object Oriented Programming in C# Chapter 2: Introduction to Visual C# Programming 1 Xiang Lian The University of Texas Rio Grande Valley Edinburg,
VISUAL C++ PROGRAMMING: CONCEPTS AND PROJECTS Chapter 1B Introduction (Tutorial)
Chapter 3 Introducing Visual Basic.NET. 3.1 Visual Basic.NET Windows Programming -Used to create Windows, Web, and Console applications -Uses predefined.
Teacher: Ms. Olifer MICROSOFT VISUAL STUDIO 2010: PROPERTIES OF WINDOWS FORM OBJECT.
1 1 Lab1 Ismail M. Romi – IT Dept, PPU, Visual Basic 2005 Programming Tour.
T U T O R I A L  2009 Pearson Education, Inc. All rights reserved. 1 2 Welcome Application Introducing the Visual Basic 2008 Express Edition IDE.
Clearly Visual Basic: Programming with Visual Basic 2008 Chapter 4 I Need a Tour Guide.
C# Tutorial -1 ASP.NET Web Application with Visual Studio 2005.
Copyright © 2001 by Wiley. All rights reserved. Chapter 2: Using Visual Basic to Create a First Project Getting Started with VB Development Environment.
Introduction to the Visual Studio.NET IDE (LAB 1 )
Introduction to Visual Basic.NET Your First Visual Basic.NET Application.
Introduction It is developed to create software applications. It is a tool for developers of any program that uses both basic and expert settings. It.
1. S:\Courses\CSSE\ibrahima\CS2340\Notes Folder Section1 Folder Section2 2.
Chapter Two Creating a First Project in Visual Basic.
CC111 Lec7 : Visual Basic 1 Visual Basic(1) Lecture 7.
Chapter 2 – Introduction to the Visual Studio .NET IDE
What is Visual Basic.NET? 110 B-1 e.g. a word processor doesn’t do anything until the user clicks on a button, types text... A programming language that.
1 CS1430: Programming in C++ Section 2 Instructor: Qi Yang 213 Ullrich
CS 2340: Programming in VB Lab 2 Due 9 pm, Friday, September 14 1.
Lab 2 Due 9 pm, Friday, September Put a “&” in button text The char after “&” is underlined and becomes the Access Key Example Text of btnExit:
 2002 Prentice Hall. All rights reserved. 1 Chapter 2 – Introduction to the Visual Studio.NET IDE Outline 2.1Introduction 2.2Visual Studio.NET Integrated.
Microsoft Visual Basic 2008: Reloaded Third Edition Chapter One An Introduction to Visual Basic 2008.
This is how you invoke the Microsoft Visual Studio 2010 Software. All Programs >> Microsoft Visual Studio 2010.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 3 Building an Application in the Visual Basic.NET Environment.
COMPUTER PROGRAMMING I 3.01 Apply Controls Associated With Visual Studio Form.
CSC 230 (Blum)1 Visual Basic 2005 Hello World Fall 2005 T. Blum.
Visual Basic.Net. Software to Install Visual Studio 2005 Professional Edition (Requires Windows XP Pro) MSDN Library for Visual Studio 2005 Available.
IE 411/511: Visual Programming for Industrial Applications Lecture Notes #2 Introduction to the Visual Basic Express 2010 Integrated Development Environment.
COMPUTER PROGRAMMING I 3.01 Apply Controls Associated With Visual Studio Form.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 2 The Visual Basic.NET Integrated Development Environment.
 2002 Prentice Hall. All rights reserved. 1 Introduction to the Visual Studio.NET IDE Outline Introduction Visual Studio.NET Integrated Development Environment.
Microsoft Visual Basic 2012: Reloaded Fifth Edition Chapter One An Introduction to Visual Basic 2012.
Dive Into® Visual Basic 2010 Express
Visual Basic Fundamental Concepts
Visual Basic Code & No.: CS 218
Introduction to Computer CC111
CSCI 3328 Object Oriented Programming in C# Chapter 2: Introduction to Visual C# Programming UTPA – Fall 2012 This set of slides is revised from lecture.
Apply Procedures to Develop Message, Input, and Dialog Boxes
Chapter 2 – Introduction to the Visual Studio .NET IDE
3.01 Apply Controls Associated With Visual Studio Form
3.01 Apply Controls Associated With Visual Studio Form
CS 2340: Programming in VB Instructor: Dr. Qi Yang Office: 213 Ullrich
VISUAL BASIC.
Visual Basic..
The University of Texas – Pan American
CIS16 Application Development Programming with Visual Basic
Building an Application in the Visual Basic .NET Environment
Introduction to Visual Basic 2010
Presentation transcript:

CS 2340 Programming in VB.NET Instructor: Dr. Qi Yang Office: 213 Ullrich Phone: YangQ 1

Web Sites

Three VB.NET Courses CS 2340: Programming in VB.NET Prerequisite: CS 1430 CS 3340: Windows Programming Prerequisite: CS 2340 & CS 2430 or CS 2630 CS 3870: Web Protocols, Technologies and Applications Prerequisite: CS 3340 Co-requisite: CS 3630 (Database) 3

CS 2340: Course Description An introduction to event driven, object oriented programming techniques in VB.NET. Students will design, code, and debug Graphic User Interface (GUI) programs and apply the techniques to business applications. 4

CS 2340: Course Outcomes Upon completion of this course, students should be able to Design and develop Graphical User Interfaces; Understand and code Event-Driven procedures; Program Visual Basic controls proficiently; Access database from VB.NET programs; and Design, develop and test Visual Basic programs. 5

CS 2340: Textbook Beginning VB.NET, 2 nd Edition, Wrox Not.NET

CS 2340: Course Work 8 Labs 160 (10 – 30 each) 6 Tests 200 (20 – 40 each) 1 Project 40 Total 400 7

Course Grading Course Grade Points Percentage Grade Points A % 4.0 A % 3.7 B % 3.3 B % 3.0 B % 2.7 C % 2.3 C % 2.0 C % 1.7 D % 1.3 D % 1.0 F below No Curve 8

Hands-on Tests In all three VB courses Paper published in Journal of Information Systems Education Volume 16, Number 2, Summer

CS 2340 Programming in VB.NET Different Backgrounds If you have a very good background You should get an A You may not get an A Else If you have a good background You do not want to get a D Else (Don’t have any background in VB) You can get an A! Come to class every day and do your work! 10

CS 2340 Programming in VB.NET Every one could get an A! That has never happened! Every one should pass CS 2340! That has never happened either! Our Slogan: Just Do It! 11

Lab 1 10 points Due 9 PM, Monday, September 10, 2012 No Grace Time! 12

MS Visual Studio 2010 Every PC in Ullrich Free Copy on your PC Will receive about it Follow instructions to get your copy 13

Create a VB.NET Solution Start MS Visual Studio 2010 New Project… Visual Basic Windows Windows Form Application Name: YangQ_Lab1 Create directory for solution: Uncheck 14

Save Project and Solution Make sure you know where is your program! Save all Create Solution folder: Uncheck Browse location Could change project / solution names Check program location 15

MS Visual Studio IDE (Integrated Development Environment) Title Bar Menu Bar Tool Bars Solution Explorer Properties Window ToolBox Auto Hide... 16

Form Properties Form - Window Text Size FormBorderStyle StartPosition WindowState... 17

Properties Window Properties Events Alphabetical Categorized 18

ToolBox Most controls available on ToolBox Tabs on ToolBox All Windows Forms Common Controls Putting a control on form Double Click Drag and Drop 19

Windows Controls TextBox Get Input Display Output Label Display Information / Output Button User action... 20

Click Event The button’s Click Event Users click a button when they want to do something. Event Procedure VB function that will be called when the event happens We will write the event procedure Click Event procedure template Double click the button 21

Declaring Variables Dim theName As String theName = txtName.Text ‘ This is comment ‘ To remove spaces from both ends theName = txtName.Text.Trim() We should get variable values from controls at the beginning, then use the variables, not the controls, in the code. 22

Class MessageBox Method Show MessageBox.Show(“Please Enter Your Name”) Caption (Title), MessageBoxButtons and MessageBoxIcon MessageBox.Show("Enter Your Name Please!", _ "Lab 1", MessageBoxButtons.OK, _ MessageBoxIcon.Exclamation) Line continuation char: “ _” VB has NO statement terminator 23

String Operations ‘ Operators “&” and “+” append strings MessageBox.Show("Hello, " & theName + "!”) MessageBox.Show("Hello, " & theName + "!", "Lab 1”, _ MessageBoxButtons.OK, _ MessageBoxIcon.Information) 24

If Statement If theName = "" Then MessageBox.Show("Enter Your Name Please!", "Lab 1", _ MessageBoxButtons.OK, _ MessageBoxIcon.Exclamation) Else MessageBox.Show("Hello, " & theName + "!", "Lab 1", _ MessageBoxButtons.OK, _ MessageBoxIcon.Information) End If 25

The Click Event Procedure Pseudo Code Private Sub btnHello_Click(...) Handles btnHello.Click ‘ Declare variable(s) ‘ Get input ‘ If empty input ‘ Display a message ‘ Else ‘ Display a different message End Sub 26

The Click Event Procedure Private Sub btnHello_Click(...) Handles btnHello.Click Dim theName As String theName = txtName.Text.Trim() If theName = "" Then MessageBox.Show("Enter Your Name Please!", "Lab 1", _ MessageBoxButtons.OK, _ MessageBoxIcon.Exclamation) Else MessageBox.Show("Hello, " & theName + "!", "Lab 1", _ MessageBoxButtons.OK, _ MessageBoxIcon.Information) End If End Sub 27