1 / 17

September 16, 2009

Visual Basic Sophomore Class Today’s Agenda: *Review of VB Screen *Look at forms and Properties H omework: Study for test on Friday. September 16, 2009. Why 9/9/09?. Extra Credit Assignment was to list 5 reasons. Here are some reasons:

heinz
Télécharger la présentation

September 16, 2009

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. Visual Basic Sophomore ClassToday’s Agenda: *Review of VB Screen*Look at forms and Properties Homework: Study for test on Friday. September 16, 2009

  2. Why 9/9/09? Extra Credit Assignment was to list 5 reasons. Here are some reasons: • The number 9 is special and can carry good or bad omens. • In Florida, a one-day wedding special for $99.99. • iPod has moved their traditional Tuesday release day to Wednesday. • New film will be opening – ‘9’ (an animated tale about the apocalypse. • Number looks good for Marketing promotions. • Represents the last set or repeating, singel-digit dates that we will see for a century (until 1/1/2101 or 1/1/3001) • The number 9 is associated with forgiveness, compassion and success on the positive side as well as arrogance and self-righteousness on the negative side. • The sum of the two-digits resulting from 9 multiplied by any other single-digit number will equal 9. • Multiply nine by any two, three or four digit number and the sum of those will also break down to 9. • Is the 252 day of the year. • The Chinese believe that the number 9 is associated with a long life. • The Japanese believe the number 9 is highly unlucky - second only to four, which sounds like death.

  3. The Visual Basic compiler starts with what?What is the name of this box?

  4. Can you name the different parts of the screen?

  5. Introduction to Microsoft Visual Basic • Microsoft Visual Basic is a software tool that allows you to create programs. • Visual Basic can be started from a shortcut on the desktop or from the Start button and programs. • Visual Basic stores programs in a group of files called a project. • Has a file extenion of VBP • Project Explorer allows you to see the forms and files that make up your program.

  6. Introduction to Microsoft Visual Basic • There is a toolbox with tools that allows you to draw command buttons, scroll bars, and much more.

  7. Introduction to Microsoft Visual Basic • The pieces that make up a Visual Basic program are called objects. • The characteristics are called properties. • The properties of an object can be changed from the Properties Window.

  8. Introduction to Microsoft Visual Basic • The Form Layout window shows the position the form will take when the programs run.

  9. Running a Visual Basic Program • To run a Visual Basic Program, click the Start button from the standard toolbar. • Or choose Run from the Menu bar.

  10. How to create a new project? • Click the Standard EXE on the New Project dialog box and then click the open button.

  11. Forms! • Each project that you create will have one default form. You can add as many forms as needed for the project. • In VB, forms become the windows and dialog boxes when the program runs.

  12. Saving the Project • When saving the project, you actually save the forms of the project and then the project itself. • Remember - you must save your forms along with your project or you cannot open your program later!

  13. Viewing and Modifying Properties • Remember – the characteristics of Visual Basic objects are called properties. • The properties window allows you to easily alter the properties of objects. • Two most important properties of a form are: • Caption • Name

  14. Caption Property • Caption • Allows you to specify the text that appears in the title bar of the form. • Allows you to specify the text that appears in a button. • Allows you to specify the text that appears in a label. • Plus much more!

  15. Name Property • Name • Each object has a name. • The name of the object becomes very important when you begin writing VB code to manipulate the objects. • When naming objects, you should use names that are meaningful and describe the object you are naming. • Use a prefix to your name!

  16. Rules to name your ob ject: Prefix Type of Object Example cmd Command Button cmdExit frm Form frmCalculator img Image imgAmy lbl Label lblPrompt txt Text txtHeight

  17. Homework: • Study for test on Friday. • Don’t forget to pick up your worksheet of questions!

More Related