An Overview of Visual Basic .NET

Publish in

Documents

5 views

Please download to get full document.

View again

of 25
All materials on our website are shared by users. If you have any questions about copyright issues, please report us to resolve them. We are always happy to assist you.
Share
Description
An Overview of Visual Basic .NET. Overview Objectives. This overview contains basic definitions and background information, including: A brief history of programming languages An introduction to the terminology used in object-oriented programming languages A Visual Basic demonstration
Transcript
An Overview of Visual Basic .NET Overview Objectives
  • This overview contains basic definitions and background information, including:
  • A brief history of programming languages
  • An introduction to the terminology used in object-oriented programming languages
  • A Visual Basic demonstration
  • Information on using the tutorials effectively
  • A Brief History of Programming Languages
  • Computers still rely on human beings to give them directions
  • These directions are called programs, and the people who write the programs are called programmers
  • Just as human beings communicate with each other through the use of languages such as English, Spanish, Hindi, and Chinese, programmers use a variety of special languages, called programming languages, to communicate with the computer
  • Machine Languages
  • Within a computer, data are represented by microscopic electronic switches that can be either off or on
  • The off switch is designated by a 0
  • The on switch is designated by a 1
  • Instructions written in 0s and 1s are called machine language or machine code
  • Each type of machine has its own language
  • Machine languages represent the only way to communicate directly with the computer
  • Assembly Languages
  • Slightly more advanced programming languages are called assembly languages
  • Assembly languages simplify the programmer’s job by allowing the programmer to use mnemonics in place of the 0s and 1s in the program
  • Mnemonics are memory aids—in this case, alphabetic abbreviations for instructions
  • Assembly Languages
  • For example, the mnemonic MOV is used to move data from one area of the computer’s memory to another
  • Programs written in an assembly language require an assembler
  • The assembler is also a program
  • It converts the assembly instructions into machine code—the 0s and 1s the computer can understand
  • High-Level Languages
  • High-level languages
  • Allow the programmer to use instructions that more closely resemble the English language
  • Represent the next major development in programming languages
  • Programs written in a high-level language require either an interpreter or a compiler to convert the English-like instructions into the 0s and 1s the computer can understand
  • High-Level Languages
  • Like assemblers, both interpreters and compilers are separate programs
  • An interpreter translates the high-level instructions into machine code, line by line, as the program is running
  • A compiler translates the entire program into machine code before running the program
  • Procedure-Oriented High-Level Languages
  • In procedure-oriented high-level languages, the emphasis of a program is on how to accomplish a task
  • The programmer must instruct the computer every step of the way, from the start of the task to its completion
  • The programmer determines and controls the order in which the computer processes the instructions
  • Procedure-Oriented High-Level Languages
  • Examples include:
  • COBOL
  • BASIC ( )
  • C
  • Procedure-oriented high-level languages are a vast improvement over machine and assembly languages
  • Some of the procedure-oriented high-level languages—for example, the BASIC language—do not require a great amount of technical expertise to write simple programs
  • The Introduction of Windows
  • Windows software provides an easy-to-use graphical user interface (GUI)
  • The GUI is common to all applications written for the Windows environment
  • Although the standard interface found in all Windows applications makes the user’s life much easier, it complicates the programmer’s life a great deal
  • The Introduction of Windows
  • Programmers found themselves spending countless hours writing instructions to create the buttons, scroll bars, dialog boxes, and menus needed in all Windows applications
  • Tasks that used to take a few lines of program code now needed pages
  • Because programming Windows applications required a great amount of expertise, it appeared that the beginning of the Windows environment meant the end of the do-it-yourself, nonprofessional programmer
  • Object-Oriented/Event-Driven High-Level Languages
  • The object-oriented/event-driven high-level languages simplified the task of programming applications for Windows
  • In object-oriented/event-driven languages, the emphasis of a program is on the objects included in the user interface (such as scroll bars and buttons) and the events (such as scrolling and clicking) that occur when those objects are used
  • The object-oriented method allows the programmer to use familiar objects to solve problems
  • Object-Oriented/Event-Driven High-Level Languages
  • The ability to use objects that model things found in the real world makes problem solving much easier
  • Visual Basic .NET is an object-oriented/event-driven programming language that is easy enough for a nonprogrammer to use, yet sophisticated enough to be used by professional programmers
  • With Visual Basic it takes just a few clicks of the mouse to include standard Windows objects such as buttons, list boxes, scroll bars, and icons in your Windows application
  • OOP Terminology
  • OOP is an acronym for object-oriented programming
  • It means that you are using an object-oriented language to create a program that contains one or more objects
  • OOD is an acronym for object-oriented design
  • Like top-down design, which is used to plan procedure-oriented programs, OOD is also a design methodology, but it is used to plan object-oriented programs
  • OOD divides a problem into one or more objects
  • OOP Terminology
  • An object is anything that can be seen, touched, or used
  • The objects used in an object-oriented program can take on many different forms
  • Objects include menus, radio buttons, and buttons included in most Windows programs
  • An object also can represent something encountered in real life
  • Every object has attributes and behaviors
  • ObjectAn Object:
  • Is Anything that can be seen or touched
  • Has attributes that describe it
  • Has behaviors that the object can either perform or have performed on it
  • OOP Terminology
  • The attributes are the characteristics that describe the object
  • An object’s behaviors, on the other hand, are the operations (actions) that the object is capable of performing
  • A class is a pattern or blueprint used to create an object
  • Every object used in an object-oriented program comes from a class
  • OOP Terminology
  • A class contains—or, in OOP terms, it encapsulates—all of the attributes and behaviors that describe the object the class creates
  • Objects created from a class are referred to as instances of the class, and are said to be “instantiated” from the class
  • Abstraction refers to the fact that the user need not be concerned with the internal details of an object. To use it it is sufficient to know what its methods and properties are.
  • This hiding of the internal details of an object from the user is known as Data Hiding.
  • Inheritance
  • Allows you to create one class from another class
  • The new class is called the derived class
  • The original class is called the base class
  • Suppose we had a base class called “Rectangle”
  • Since a square is a rectangle with some additional properties, the class “Square” could be defined using inheritance from the “Rectangle” class
  • OOP Terminology
  • Attributes and behaviors that are not hidden are said to be exposed to the user
  • Polymorphism is the object-oriented feature that allows the same instruction to be carried out differently depending on the object
  • Example: The Area method for a Rectangle is Area = L x W. For a square it can be simplified to Area = s2
  • Object Oriented Languages
  • C++ descended from C, its older ancestor
  • Java, used for web development
  • Javascript, not related to Java, but is OOPs
  • C# is a new offspring of C++ oriented for rapid development and web development
  • Visual Basic.Net is the newest version of Visual Basic. VB.Net supports both Windows application development and Web application development
  • Monthly Payment ApplicationAn example of an OOPs programUsing the Tutorials Effectively
  • The tutorials in this book will help you learn about Microsoft Visual Basic .NET, the newest version of the Visual Basic programming language
  • At the end of Lesson C in each tutorial you will find one or more Debugging exercises
  • In programming, the term debugging refers to the process of finding and fixing any errors in a program
  • Using the Tutorials Effectively
  • Hands-on at your computer
  • Step-by-step approach
  • Help? notes identify common problems and explain how to get back on track
  • Tip notes provide additional information about a procedure
  • Each tutorial is divided into three lessons
  • To review and reinforce a lesson’s concepts
  • Summary
  • Questions
  • Exercises
  • Related Search

    Previous Document

    Revelation Chapter 15

    We Need Your Support
    Thank you for visiting our website and your interest in our free products and services. We are nonprofit website to share and download documents. To the running of this website, we need your help to support us.

    Thanks to everyone for your continued support.

    No, Thanks