Created by Alia Al-Abdulkarim 2008 Visual Basic Vs. Java.

Slides:



Advertisements
Similar presentations
Midterm 26 March 2015 (4:30-5:30 pm) – Rm5620 Closed book exam MC Questions only x25 Up to L(7) Methods Scope: video lectures (+Lab), forum discussions,
Advertisements

Practical Programming COMP153-08S Lecture: Repetition Continued.
Compunet Corporation Programming with Visual Studio.NET GUI Week 13 Tariq Aziz and Kevin Jones.
Multiple Forms & Procedures. Form Methods: –Show, Hide, Activate, Close Events: –Load, Activated, Closing, Closed.
Coding ADO.NET Objects: Connection, Command, DataReader.
More on lists, exceptions, loops and validation. You can use the exception to indicate the error that occurred Private Sub btnCheck_Click(ByVal sender.
Visual Basic Fundamental Concepts. Integrated Development Enviroment Generates startup form for new project on which to place controls. Features toolbox.
Visual Basic 2008 Express Edition The IDE. Visual Basic 2008 Express The Start Page Recent Projects Open an existing project Create a New Project.
Chapter 6 Procedures and Functions Instructor: Bindra Shrestha University of Houston – Clear Lake CSCI
1 Visual Basic for Applications (VBA) for Excel Prof. Yitzchak Rosenthal.
Why to Create a Procedure
1 Κατανεμημένες Διαδικτυακές Εφαρμογές Πολυμέσων Γιάννης Πετράκης.
1 Κατανεμημένες Διαδικτυακές Εφαρμογές Πολυμέσων Γιάννης Πετράκης.
Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Technology Education Assignment #1 Advanced Computer Programming.
Microsoft Access Using Visual Basic Routines. Visual Basic Datatypes Boolean Byte Currency Date Double Integer Long Object Single String Variant Hyperlink.
Lecture 8 Visual Basic (2).
COMPUTER PROGRAMMING I Objective 7.03 Apply Built-in Math Class Functions.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 4 Working with Variables, Constants, Data Types, and Expressions.
1/31 5/6/2014 BAZELE PROGRMARII PE OBIECTE PROIECTE IN VISUAL BASIC Conf univ dr Botezatu Cezar INFORMATICĂ MANAGERIALĂ Anul I. STUDII DE LICENŢĂ.
1 CC111 Lec9 : Visual Basic Visual Basic (3) Lecture 9.
VB Procedures. Procedures. Sub procedure: Private/Public Sub SubName(Arguments) … End Sub Private: Can only be accessed by procedures in the same form.
Visual Basic.NET Windows Forms Hello World Homework Assignment.
IMS 3253: Subroutines 1 Dr. Lawrence West, MIS Dept., University of Central Florida Topics Procedures Subroutines Parameters –By Value.
CS0004: Introduction to Programming Project 1 – Lessons Learned.
ADO.NET Objects – Data Providers Dr. Ron Eaglin. Requirements Visual Studio 2005 Microsoft SQL Server 2000 or 2005 –Adventure Works Database Installed.
Module 3: Using Microsoft.NET- Based Languages. Overview Overview of the.NET-Based Languages Comparison of the.NET-Based Languages.
Applications Development
© 2006 ITT Educational Services Inc. Introduction to Computer Programming: Unit 10: Chapter 6: Slide 1 Unit 10 Sub Procedures and Functions Chapter 6 Sub.
6c – Function Procedures Lingma Acheson Department of Computer and Information Science, IUPUI CSCI N331 VB.NET Programming.
1 Advanced Computer Programming Lab Calculator Project.
PSU CS 106 Computing Fundamentals II VB Declarations HM 5/4/2008.
PRACTICE SAC 1 Some solutions. 'inputs 'sale price 'postcode 'coupon codes 'processing 'calculate commissions (commission based on cost) 'calculate postage.
CIVIL AND GEOMATIC ENGINEERING FT Okyere. CIV 257- COMPUTER PROGRAMMING Lecture 3.
Week Procedures And Functions 7 A procedure is a collection of statements that performs a task.
6b – Sub Procedure With Parameters Lingma Acheson Department of Computer and Information Science, IUPUI CSCI N331 VB.NET Programming.
Using ADO.Net to Build a Login System Dr. Ron Eaglin.
Practical Programming COMP153-08S Lecture: Repetition.
ADO.NET Objects Data Adapters Dr. Ron Eaglin. Agenda Builds on Information in Part I Should have working knowledge of creating a database connection Continuation.
مقدمة في البرمجة Lecture 7. Write VB.net project using the for loop to calculate : 1- the sum of numbers from 1 to (A) numbers. 2- the sum of Odd numbers.
Visual Basic. The Close Method The Close method is used to close a form. To close a form use the keyword Me to refer to the form. Me.Close()
Introduction to VB programming Dr. John P. Abraham UTPA Chapters 2 & 3.
Starting Out with Visual Basic.NET 2 nd Edition Chapter 6 Sub Procedures And Functions.
MIC305 Week 6 Beyond controls Review of properties Differences with VB6: using classes and instances Programming constructs.
COM148X1 Interactive Programming Lecture 8. Topics Today Review.
1 Computer Programming Andres, Wen-Yuan Liao Department of Computer Science and Engineering De Lin Institute of Technology
Addison Wesley is an imprint of © 2011 Pearson Addison-Wesley. All rights reserved. Addison Wesley is an imprint of Chapter 3 Variables and Calculations.
T HE W ALKING FOR W ATER P ROJECT IE 2060 Katelyn Cockrell Alexis Duran Theresa Garcia.
Visual Basic Declaring Variables Dim x as Integer = 0 In the statement above, x is being declared as an Integer (whole number) and is initialised.
Computer Science Up Down Controls, Decisions and Random Numbers.
Directory and File. Access Files in a Directory Name space: System.IO The Directory and File classes contain only shared methods that set or return information.
Data Types. Visual Basic provides data type Single for storing single-precision floating-point numbers. Data type Double requires more memory to store.
Lecture 7 Methods (functions and subroutines) Parameter Passing
CS0004: Introduction to Programming
Introduction to Programming Lecture 3 Msury Mahunnah, Department of Informatics, Tallinn University of Technology.
Sub Procedures And Functions
Use TryParse to Validate User Input
Visual Basic Fundamental Concepts
Objective 7.03 Apply Built-in Math Class Functions
Royal University of Phnom Penh
Use TryParse to Validate User Input
Introduction to VB programming
للمزيد زورونا على موقعنا الإلكتروني:
Visual Basic..
Boolean Expressions and If statements
1.الدوال Function 2.الاجراءاتSub Procedure 3.وحده نمطيه Add Module
Coding ADO.NET Objects: Connection, Command, DataReader
STARTING OUT WITH Visual Basic 2008
GUI Programming in Visual Studio .NET
Final Revision sheet- term2
Web Service.
Presentation transcript:

Created by Alia Al-Abdulkarim 2008 Visual Basic Vs. Java

Created by Alia Al-Abdulkarim 2008 Variables Dim a As Double = 3.0 Dim b As Double = 4.0

Created by Alia Al-Abdulkarim 2008 Loops While Loop While (i <> limit) sum += i i+=1 End While

Created by Alia Al-Abdulkarim 2008 Loops cont. For Loop For i = 1 To 5 Step Next

Created by Alia Al-Abdulkarim 2008 Select Case Select Case (choice) Case Case Case Case Else End Select

Created by Alia Al-Abdulkarim 2008 Visual Basic Visual Basic Functions and Subs Scopes Events

Created by Alia Al-Abdulkarim 2008 Functions and Subs Function Piece of code that is executed upon a function call. Always returns a value May receive parameters Sub Same as function, but it doesn’t return a value

Created by Alia Al-Abdulkarim 2008 Functions and Subs cont. Function function-name (ByVal Para1 As data-type, ……..) As data-type Return variable End Function

Created by Alia Al-Abdulkarim 2008 Functions and Subs Cont. Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Function function-name (ByVal Para1 As data-type, ……..) As data-type Return variable End Function End Sub Functions’ Definitions Can Not Be Nested

Created by Alia Al-Abdulkarim 2008 Scopes Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim A As Integer End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click A = 10 End Sub Variable Declaration isn’t visible here

Created by Alia Al-Abdulkarim 2008 Events When do we use them? Example When I want the value in the textbox printed on a label after the button is clicked, I create an Event that reads from the textbox and writes on a label Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim var As String var = TextBox1.Text Label1.Text = var End Sub

Created by Alia Al-Abdulkarim 2008 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim a As Integer = 0 End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click TextBox1.Text = a End Sub Quiz: What is the Problem? Variable Declaration isn’t visible here