1 / 21

Introduction to Visual Basic and Object Oriented Programming

Introduction to Visual Basic and Object Oriented Programming. Important Information. Visual Studio 2015/2017 www.visualstudio.com Course web site http://www.condesigns.com Contact Office Hours – Upon request E-mail: adepinto@gmail.com. Introduction.

enoon
Télécharger la présentation

Introduction to Visual Basic and Object Oriented Programming

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to Visual Basic and Object Oriented Programming

  2. Important Information • Visual Studio 2015/2017 • www.visualstudio.com • Course web site • http://www.condesigns.com • Contact • Office Hours – Upon request • E-mail: adepinto@gmail.com

  3. Introduction • Computers process data under the control of sequences of instructions called computer programs. • These programs guide the computer through actions specified by people called computer programmers. • The programs that run on a computer are referred to as software.

  4. Data Hierarchy • Data items processed by computers form a data hierarchy that becomes larger and more complex in structure as we progress from the simplest data items (called “bits”) to richer data items, such as characters, fields, and so on.

  5. Data Hierarchy • Bits - The smallest data item in a computer can assume the value 0 or the value 1. • Characters - We prefer to work with decimal digits (0–9), uppercase letters (A–Z), lowercase letters (a–z), and special symbols. Computers process only 1s and 0s, so every character is represented as a pattern of 1s and 0s.

  6. ASCII Table

  7. Data Hierarchy • Fields - Just as characters are composed of bits, fields are composed of characters or bytes. A field is a group of characters or bytes that conveys meaning. For example, a field consisting of uppercase and lowercase letters could be used to represent a person’s name, and a field consisting of decimal digits could represent a person’s age.

  8. Data Hierarchy Records Several related fields can be used to compose a record. In a payroll system, for example, the record for an employee might consist of the following fields (possible types for these fields are shown in parentheses): Employee identification number (a whole number) Name (a string of characters) Address (a string of characters) Hourly pay rate (a number with a decimal point) Year-to-date earnings (a number with a decimal point) Amount of taxes withheld (a number with a decimal point) Thus, a record is a group of related fields.

  9. Data Hierarchy • Files - A file is a group of related records. • Database - A database is a collection of data that’s organized for easy access and manipulation. The most popular database model is the relational database in which data is stored in simple tables. • A table includes records composed of fields. • For example, a table of students might include first name, last name, major, year, student ID number and grade point average fields. • The data for each student is a record, and the individual pieces of information in each record are the fields.

  10. Machine Languages, Assembly Languages and High-Level Languages Machine Languages - Any computer can directly understand only its own machine language, defined by its hardware architecture.Machine languages generally consist of numbers, ultimately reduced to 1s and 0s. Assembly Languages and Assemblers - Machine language too slow and tedious. Assembly language uses abbreviations to represent elementary operations. Translator programs called assemblers convert assembly-language programs to machine language quickly. High-Level Languages, Compilers and Interpreters - developed so single statements could be written to accomplish substantial tasks.Translator programs called compilers convert high-level-language code into machine language code.

  11. Machine Languages, Assembly Languages and High-Level Languages

  12. Visual Basic • Visual Basic evolved from BASIC (Beginner’s All-purpose Symbolic Instruction Code), developed in the mid-1960s at Dartmouth College as a language for introducing novices to fundamental programming techniques. • In the late 1980s and the early 1990s, Microsoft developed its Windows graphical user interface (GUI)—the visual part of the operating system with which users interact.

  13. Visual Basic • With the creation of the Windows GUI, the natural evolution of BASIC was to Visual Basic, introduced by Microsoft in 1991 to make programming Windows apps easier. • Visual Basic 6 was introduced in 1998. It was designed to make programming fast and easy, however it was not intended for building industrial strength apps. • In 2002, Microsoft released Visual Basic .NET—a more robust language that’s appropriate for the most demanding app development tasks.

  14. Microsoft’s .NET • In 2000, Microsoft announced its .NET initiative, a broad vision for using the Internet and the web in the development, engineering, distribution and use of software. • .NET permits developers to create apps in any .NET-compatible language (such as Visual Basic, C# and others). • Part of the initiative includes Microsoft’s ASP.NET technology, which is used to create web apps that users interact with via their web browsers.

  15. Common Language Runtime • The Common Language Runtime (CLR) executes .NET programs and provides functionality to make them easier to develop and debug. • The CLR is a virtual machine (VM)—software that manages the execution of programs and hides from them the underlying operating system and hardware. • The source code for programs that are executed and managed by the CLR is called managed code.

  16. Visual Studio .NET • Included in Visual Studio .NET 2013 • Visual Basic (can also be purchased separately) • Visual C++ • C# (C sharp) • .NET 4.5+ Framework • Visual Studio .NET Editions • Community • Professional • Enterprise

  17. Object-Oriented Programming • Visual Basic .NET is object oriented. • Visual Basic has access to the powerful .NET Framework Class Library—a vast collection of prebuilt components that enable you to develop apps quickly.

  18. Object Terminology Objects, or more precisely the classes objects come from, are essentially reusable software components. There are date objects, time objects, audio objects, video objects, automobile objects, people objects, etc. Objects equate to Nouns. Forms are windows. Controls are components contained inside a form. Properties equate to Adjectives. Color or size of a Form Methods are like Verbs. Typical methods include Close, Show and Clear

  19. Object Terminology In object-oriented programming languages, we create a program unit called a class to house the set of methods that perform the class’s tasks. A class is similar in concept to a car’s engineering drawings, which house the design of an accelerator pedal, steering wheel, and so on. Enables people with little or no knowledge of how engines, braking and steering mechanisms work to drive a car easily.

  20. Object Terminology - Classes Class = Automobile Object = Each individual auto is an object. Object is also an Instance of the automobile class. Properties of Automobile class= make, model, color, year Car.color = Red Methods = start, stop, speedup, slowdown Car.Start(), Car.Stop(), Car.Brake() Pressing Brake causes the car to stop. “How” is hidden though. Events of automobile class = Arrive, Crash

More Related